Skip to content

Commit fe45192

Browse files
author
cw
committed
fix: 修复 IPA 重新打包时的文件覆盖问题
1 parent 21d4062 commit fe45192

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.github/workflows/ios-app-store.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,8 @@ jobs:
153153
154154
# Find the IPA file
155155
IPA_FILE=$(find build/ios/ipa -name "*.ipa" | head -n 1)
156+
IPA_DIR=$(dirname "$IPA_FILE")
157+
IPA_NAME=$(basename "$IPA_FILE")
156158
157159
# Create a temporary directory
158160
TEMP_DIR=$(mktemp -d)
@@ -171,7 +173,11 @@ jobs:
171173
172174
# Repackage the IPA
173175
cd "$TEMP_DIR"
174-
zip -qr "$IPA_FILE" Payload
176+
NEW_IPA="$TEMP_DIR/fixed.ipa"
177+
zip -qr "$NEW_IPA" Payload
178+
179+
# Replace the original IPA
180+
mv "$NEW_IPA" "$IPA_FILE"
175181
cd -
176182
177183
# Cleanup

0 commit comments

Comments
 (0)