Skip to content

Commit

Permalink
create xcframework
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasromanomr committed Nov 29, 2024
1 parent 9b5da6b commit 62a0e10
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
build:
name: Build XCFramework for Multiple Platforms
name: Build XCFramework
runs-on: macos-latest
strategy:
matrix:
Expand Down Expand Up @@ -46,10 +46,17 @@ jobs:
xcodebuild archive \
-scheme "${{ matrix.build-config.scheme }}" \
-destination "${{ matrix.build-config.destination }}" \
-configuration Release \
-sdk "${{ matrix.build-config.sdk }}" \
-archivePath "${{ matrix.build-config.archive_path }}/SkeletonView.xcarchive" \
SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
- name: Upload archive as artifact
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.build-config.sdk }}-build
path: ${{ matrix.build-config.archive_path }}

create-xcframework:
name: Create XCFramework
needs: build
Expand All @@ -59,10 +66,13 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

- name: Download build artifacts
uses: actions/download-artifact@v4
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: build-artifacts
path: build/

- name: Verify downloaded artifacts
run: ls -R build/

- name: Create XCFramework
run: |
Expand All @@ -73,16 +83,8 @@ jobs:
-framework build/Release-appletvsimulator/SkeletonView.xcarchive/Products/Library/Frameworks/SkeletonView.framework \
-output build/XCFramework/SkeletonView.xcframework
- name: Verify XCFramework
run: |
if [ -d "build/XCFramework/SkeletonView.xcframework" ]; then
echo "XCFramework generated successfully."
else
echo "Failed to generate XCFramework." && exit 1
fi
- name: Upload XCFramework
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v3
with:
name: SkeletonView-XCFramework
path: build/XCFramework/SkeletonView.xcframework
Expand Down

0 comments on commit 62a0e10

Please sign in to comment.