Skip to content

Commit 4696626

Browse files
committed
debug ios cicd
1 parent ff5bc21 commit 4696626

File tree

1 file changed

+18
-2
lines changed

1 file changed

+18
-2
lines changed

.github/workflows/ios-testflight.yml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,22 @@ jobs:
5757
p12-password: ${{ secrets.IOS_DIST_P12_PASSWORD }}
5858
mobileprovision-file-base64: ${{ secrets.IOS_MOBILEPROVISION_BASE64 }}
5959

60+
- name: Extract provisioning profile UUID
61+
id: profile
62+
run: |
63+
echo "${{ secrets.IOS_MOBILEPROVISION_BASE64 }}" | base64 --decode > profile.mobileprovision
64+
PLIST=$(mktemp)
65+
security cms -D -i profile.mobileprovision > "$PLIST"
66+
UUID=$(/usr/libexec/PlistBuddy -c 'Print :UUID' "$PLIST")
67+
NAME=$(/usr/libexec/PlistBuddy -c 'Print :Name' "$PLIST")
68+
APPID=$(/usr/libexec/PlistBuddy -c 'Print :Entitlements:application-identifier' "$PLIST")
69+
echo "PROFILE_UUID=$UUID" >> $GITHUB_ENV
70+
echo "PROFILE_NAME=$NAME" >> $GITHUB_ENV
71+
echo "APPID=$APPID" >> $GITHUB_ENV
72+
echo "uuid=$UUID" >> $GITHUB_OUTPUT
73+
echo "name=$NAME" >> $GITHUB_OUTPUT
74+
echo "Extracted profile: $NAME ($UUID) for $APPID"
75+
6076
- name: Bump build number
6177
working-directory: ios
6278
run: xcrun agvtool new-version -all $GITHUB_RUN_NUMBER
@@ -74,7 +90,7 @@ jobs:
7490
PRODUCT_BUNDLE_IDENTIFIER=com.routstr.localplusplus \
7591
CODE_SIGN_STYLE=Manual \
7692
CODE_SIGN_IDENTITY="Apple Distribution" \
77-
PROVISIONING_PROFILE_SPECIFIER="${{ secrets.IOS_PROVISIONING_PROFILE_NAME }}" \
93+
PROVISIONING_PROFILE="$PROFILE_UUID" \
7894
COMPILER_INDEX_STORE_ENABLE=NO \
7995
-allowProvisioningUpdates
8096
@@ -99,7 +115,7 @@ jobs:
99115
<key>provisioningProfiles</key>
100116
<dict>
101117
<key>com.routstr.localplusplus</key>
102-
<string>${{ secrets.IOS_PROVISIONING_PROFILE_NAME }}</string>
118+
<string>${PROFILE_NAME}</string>
103119
</dict>
104120
<key>authenticationKeyID</key>
105121
<string>${{ vars.APPSTORE_API_KEY_ID }}</string>

0 commit comments

Comments
 (0)