Skip to content

Offline gym log for Android. No account, no ads, no internet.

Add unsigned IPA build workflow

InlitX5b1acc15e7e9
diff --git a/.github/workflows/build-ios.yml b/.github/workflows/build-ios.yml
new file mode 100644
index 0000000..3fd74ab
--- /dev/null
+++ b/.github/workflows/build-ios.yml
@@ -0,0 +1,80 @@
+name: Build iOS
+
+on:
+ push:
+ branches: [main]
+ paths:
+ - 'ios/**'
+ - 'lib/**'
+ - 'pubspec.yaml'
+ - 'pubspec.lock'
+ - '.github/workflows/build-ios.yml'
+ pull_request:
+ branches: [main]
+ paths:
+ - 'ios/**'
+ - '.github/workflows/build-ios.yml'
+ workflow_dispatch:
+ inputs:
+ tag:
+ description: 'Existing release tag to attach the IPA to, e.g. v1.2.0 (leave empty to only upload the artifact)'
+ required: false
+ type: string
+
+permissions:
+ contents: write
+
+env:
+ FLUTTER_VERSION: '3.41.9'
+
+jobs:
+ build:
+ name: Build unsigned IPA
+ runs-on: macos-latest
+
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v4
+
+ - name: Set up Flutter
+ uses: subosito/flutter-action@v2
+ with:
+ channel: stable
+ flutter-version: ${{ env.FLUTTER_VERSION }}
+ cache: true
+
+ - name: Show versions
+ run: |
+ flutter --version
+ xcodebuild -version
+
+ - name: Install dependencies
+ run: flutter pub get
+
+ # No signing certificate lives in this repo: the IPA is unsigned and meant
+ # for sideloading (AltStore, Sideloadly, TrollStore…) or for re-signing
+ # with your own Apple account.
+ - name: Build (no codesign)
+ run: flutter build ios --release --no-codesign
+
+ - name: Package IPA
+ run: |
+ mkdir -p build/ipa/Payload
+ cp -R build/ios/iphoneos/Runner.app build/ipa/Payload/GymMane.app
+ cd build/ipa
+ zip -qr GymMane-unsigned.ipa Payload
+ ls -la GymMane-unsigned.ipa
+
+ - name: Upload IPA artifact
+ uses: actions/upload-artifact@v4
+ with:
+ name: gymmane-ios-unsigned
+ path: build/ipa/GymMane-unsigned.ipa
+ if-no-files-found: error
+
+ - name: Attach to release
+ if: github.event_name == 'workflow_dispatch' && inputs.tag != ''
+ uses: softprops/action-gh-release@v2
+ with:
+ tag_name: ${{ inputs.tag }}
+ files: build/ipa/GymMane-unsigned.ipa