-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Build on each XCode version available on the runner
- Loading branch information
Showing
5 changed files
with
109 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: Setup Gradle and run a task on all modules that have it | ||
description: Includes setting up JDK | ||
inputs: | ||
target: | ||
description: The release to attach to | ||
required: true | ||
xcodeversion: | ||
description: The Xcode version to configure before compiling | ||
required: true | ||
runs: | ||
using: composite | ||
steps: | ||
- uses: actions/checkout@v3.5.3 | ||
- uses: maxim-lobanov/setup-xcode@v1.6.0 | ||
with: | ||
xcode-version: ${{ inputs.xcodeversion }} | ||
- uses: ./.github/actions/runGradleTask | ||
with: | ||
task: :library:assembleLibraryReleaseXCFramework | ||
- run: zip -r Library.xcframework.zip library/build/XCFrameworks/release/library.xcframework | ||
- uses: actions/download-artifact@v4.1.4 | ||
with: | ||
name: upload_url | ||
- run: echo UPLOAD_URL=$(cat upload_url | sed "s/{?name,label}/?name=Library-${{ inputs.target }}-xcodebuild-${{ matrix.xcodeversion }}.xcframework.zip/") >> $GITHUB_ENV | ||
- run: | | ||
curl -s \ | ||
-X POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "Authorization: Bearer $GITHUB_TOKEN" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
-H "Content-Type: application/octet-stream" \ | ||
--data-binary "@Library.xcframework.zip" \ | ||
$UPLOAD_URL | ||
- run: echo $(swift package compute-checksum Library.xcframework.zip) > checksum | ||
- run: echo UPLOAD_URL=$(cat upload_url | sed "s/{?name,label}/?name=Library-${{ inputs.target }}-xcodebuild-${{ matrix.xcodeversion }}.xcframework.zip.checksum/") >> $GITHUB_ENV | ||
- run: | | ||
curl -s \ | ||
-X POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "Authorization: Bearer $GITHUB_TOKEN" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
-H "Content-Type: application/octet-stream" \ | ||
--data-binary "@checksum" \ | ||
$UPLOAD_URL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters