mirror of
https://github.com/zarzet/SpotiFLAC-Mobile.git
synced 2026-09-29 21:02:09 +02:00
fix(ios): keep release feed bundle identity in sync
Use com.zarz.spotiflac for the app and matching test targets. Read the bundle identifier from the built IPA when updating apps.json so the release feed matches the distributed application. Validation: Xcode project plist lint and binary IPA bundle identifier extraction passed.
This commit is contained in:
@@ -449,6 +449,19 @@ jobs:
|
||||
fi
|
||||
|
||||
IPA_SIZE=$(stat -c%s "$IPA_FILE" 2>/dev/null || stat -f%z "$IPA_FILE")
|
||||
BUNDLE_ID=$(python3 - "$IPA_FILE" <<'PY'
|
||||
import plistlib
|
||||
import sys
|
||||
import zipfile
|
||||
|
||||
with zipfile.ZipFile(sys.argv[1]) as ipa:
|
||||
info_path = next(name for name in ipa.namelist()
|
||||
if name.startswith("Payload/")
|
||||
and name.count("/") == 2
|
||||
and name.endswith(".app/Info.plist"))
|
||||
print(plistlib.loads(ipa.read(info_path))["CFBundleIdentifier"])
|
||||
PY
|
||||
)
|
||||
|
||||
if [ ! -f apps.json ]; then
|
||||
echo "WARNING: apps.json not found on main, skipping"
|
||||
@@ -456,10 +469,11 @@ jobs:
|
||||
fi
|
||||
|
||||
jq --arg ver "$VERSION_NUM" \
|
||||
--arg bundle "$BUNDLE_ID" \
|
||||
--arg date "$DATE" \
|
||||
--arg url "https://github.com/${REPOSITORY}/releases/download/${VERSION}/SpotiFLAC-${VERSION}-ios-unsigned.ipa" \
|
||||
--argjson size "$IPA_SIZE" \
|
||||
'.apps[0].version = $ver | .apps[0].versionDate = $date | .apps[0].downloadURL = $url | .apps[0].size = $size' \
|
||||
'.apps[0].bundleIdentifier = $bundle | .apps[0].version = $ver | .apps[0].versionDate = $date | .apps[0].downloadURL = $url | .apps[0].size = $size' \
|
||||
apps.json > apps.json.tmp && mv apps.json.tmp apps.json
|
||||
|
||||
echo "Updated apps.json:"
|
||||
|
||||
Reference in New Issue
Block a user