Skip to content

Commit fc8b99d

Browse files
authored
Update GitHub Actions workflow for IPA build
1 parent d73439c commit fc8b99d

File tree

1 file changed

+42
-20
lines changed

1 file changed

+42
-20
lines changed

.github/workflows/build_ipa.yml

Lines changed: 42 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -8,45 +8,68 @@ on:
88
workflow_dispatch:
99

1010
permissions:
11-
contents: write
12-
11+
contents: write
12+
1313
jobs:
1414
build:
1515
name: Build Debug IPA
16-
runs-on: macos-latest
16+
runs-on: macos-latest
1717

1818
steps:
1919
- name: Checkout
2020
uses: actions/checkout@v4
21-
22-
- name: Setup Xcode (latest stable)
21+
22+
- name: Setup Xcode
2323
uses: maxim-lobanov/setup-xcode@v1
2424
with:
25-
xcode-version: 'latest-stable'
26-
27-
- name: Archive Build (Debug, Unsigned)
25+
xcode-version: '26.1'
26+
27+
- name: Diagnostics (helpful in logs)
28+
run: |
29+
set -euxo pipefail
30+
xcodebuild -version
31+
xcode-select -p
32+
xcodebuild -showsdks
33+
34+
- name: Resolve Swift Packages (device-only)
35+
run: |
36+
set -euxo pipefail
37+
xcodebuild -resolvePackageDependencies \
38+
-project StikDebug.xcodeproj \
39+
-scheme "StikDebug" \
40+
-destination 'generic/platform=iOS' \
41+
-skipPackagePluginValidation
42+
43+
- name: Archive Build (Debug, Unsigned, Device-only)
2844
run: |
45+
set -euxo pipefail
2946
xcodebuild clean archive \
3047
-project StikDebug.xcodeproj \
3148
-scheme "StikDebug" \
3249
-configuration Debug \
33-
-archivePath build/StikDebug.xcarchive \
34-
-sdk iphoneos \
50+
-archivePath "$PWD/build/StikDebug.xcarchive" \
3551
-destination 'generic/platform=iOS' \
36-
ONLY_ACTIVE_ARCH=NO \
37-
CODE_SIGN_IDENTITY="" \
38-
CODE_SIGNING_REQUIRED=NO \
52+
-derivedDataPath "$PWD/build/DerivedData" \
3953
CODE_SIGNING_ALLOWED=NO \
54+
CODE_SIGNING_REQUIRED=NO \
55+
CODE_SIGN_IDENTITY="" \
56+
SKIP_INSTALL=NO \
57+
BUILD_LIBRARY_FOR_DISTRIBUTION=NO \
58+
TEST_AFTER_BUILD=NO \
59+
ENABLE_TESTABILITY=NO \
60+
COMPILER_INDEX_STORE_ENABLE=NO \
4061
SWIFT_OPTIMIZATION_LEVEL="-Onone" \
4162
IPHONEOS_DEPLOYMENT_TARGET=17.4
4263
4364
- name: Create IPA from Archive
4465
run: |
45-
cp -R build/StikDebug.xcarchive/Products/Applications/StikDebug.app .
66+
set -euxo pipefail
67+
APP_PATH="$PWD/build/StikDebug.xcarchive/Products/Applications/StikDebug.app"
68+
test -d "$APP_PATH" # fail early if archive didn't produce the .app
4669
mkdir -p Payload
47-
cp -R StikDebug.app Payload/
48-
zip -r StikDebug.ipa Payload
49-
rm -rf Payload StikDebug.app
70+
cp -R "$APP_PATH" Payload/
71+
(cd Payload && zip -r ../StikDebug.ipa .)
72+
rm -rf Payload
5073
5174
- name: Upload Debug IPA (artifact)
5275
uses: actions/upload-artifact@v4
@@ -62,9 +85,8 @@ jobs:
6285
tag_name: GitHub-Alpha
6386
name: GitHub-Alpha
6487
prerelease: true
65-
generate_release_notes: true
88+
generate_release_notes: false
6689
target_commitish: ${{ github.sha }}
67-
files: |
68-
StikDebug.ipa
90+
files: StikDebug.ipa
6991
env:
7092
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)