fix ci #12
Workflow file for this run
This file contains hidden or 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
| name: Build iOS Library | |
| on: push | |
| jobs: | |
| build: | |
| name: Build for aarch64-apple-ios | |
| runs-on: [self-hosted, macOS, ARM64] | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| - name: Build for aarch64-apple-ios | |
| run: cargo build --target aarch64-apple-ios --lib --release | |
| - name: Update dylib | |
| run: | | |
| cd target/aarch64-apple-ios/release | |
| lipo "libchums_proxy.dylib" -output "libchums_proxy" -create | |
| - name: Clone flutter-chums-proxy repository | |
| run: | | |
| git clone https://github.com/Chums-Team/flutter-chums-proxy.git flutter-chums-proxy | |
| - name: ZIP artifacts | |
| run: | | |
| mkdir -p dist | |
| cp target/aarch64-apple-ios/release/libchums_proxy.* dist/ | |
| cp -r flutter-chums-proxy/chums_proxy_ios/ios/Frameworks/libchums_proxy.xcframework dist/ | |
| cp target/aarch64-apple-ios/release/libchums_proxy dist/libchums_proxy.xcframework/ios-arm64/libchums_proxy.framework | |
| cd dist/ | |
| zip -r chums-proxy-ios.zip . | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: chums-proxy-ios | |
| path: dist/chums-proxy-ios.zip | |
| release: | |
| name: Create GitHub Release | |
| runs-on: [self-hosted, macOS, ARM64] | |
| needs: build | |
| steps: | |
| - name: Download artifact | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: chums-proxy-ios | |
| path: dist | |
| - name: Generate timestamp | |
| id: meta | |
| run: | | |
| timestamp="$(date +'%Y-%m-%dT%H-%M-%S')" | |
| echo "tag_name=v$timestamp" >> "$GITHUB_OUTPUT" | |
| echo "release_name=Release ${timestamp//T/ }" >> "$GITHUB_OUTPUT" | |
| - name: Create GitHub Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| name: ${{ steps.meta.outputs.release_name }} | |
| tag_name: ${{ steps.meta.outputs.tag_name }} | |
| files: dist/chums-proxy-ios.zip | |
| generate_release_notes: true | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |