chore(ios): fix script

This commit is contained in:
devthejo 2026-01-12 22:54:20 +01:00
parent 1b98fab868
commit e1d87bb261
3 changed files with 275 additions and 194 deletions

View file

@ -197,9 +197,11 @@
9E6F0A1338934BA5AD468D4B /* Fix Xcode 15 Bug */, 9E6F0A1338934BA5AD468D4B /* Fix Xcode 15 Bug */,
229987488EA44E69AA932D58 /* Fix Xcode 15 Bug */, 229987488EA44E69AA932D58 /* Fix Xcode 15 Bug */,
A891237ADBD54747890A99FB /* Fix Xcode 15 Bug */, A891237ADBD54747890A99FB /* Fix Xcode 15 Bug */,
B700EE07E2A24654A0953D3B /* Remove signature files (Xcode workaround) */,
9E272D599E42446BB8DFD8D0 /* Fix Xcode 15 Bug */, 9E272D599E42446BB8DFD8D0 /* Fix Xcode 15 Bug */,
CBAD4F53ADB04F499371D5DE /* Remove signature files (Xcode workaround) */, 884372829D0E4436B7BC6F91 /* Fix Xcode 15 Bug */,
F778935A7C8642C4851AE054 /* Remove signature files (Xcode workaround) */,
A1D9EF7E0B4442DF8860F6A5 /* Fix Xcode 15 Bug */,
B6A277D5FA3848ECACDAF93C /* Remove signature files (Xcode workaround) */,
); );
buildRules = ( buildRules = (
); );
@ -1066,6 +1068,74 @@ fi";
shellScript = " shellScript = "
echo \"Remove signature files (Xcode workaround)\"; echo \"Remove signature files (Xcode workaround)\";
rm -rf \"$CONFIGURATION_BUILD_DIR/MapLibre.xcframework-ios.signature\"; rm -rf \"$CONFIGURATION_BUILD_DIR/MapLibre.xcframework-ios.signature\";
";
};
884372829D0E4436B7BC6F91 /* Fix Xcode 15 Bug */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
name = "Fix Xcode 15 Bug";
inputPaths = (
);
outputPaths = (
);
shellPath = /bin/sh;
shellScript = "if [ \"$XCODE_VERSION_MAJOR\" = \"1500\" ]; then
echo \"Remove signature files (Xcode 15 workaround)\"
find \"$BUILD_DIR/${CONFIGURATION}-iphoneos\" -name \"*.signature\" -type f | xargs -r rm
fi";
};
F778935A7C8642C4851AE054 /* Remove signature files (Xcode workaround) */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
name = "Remove signature files (Xcode workaround)";
inputPaths = (
);
outputPaths = (
);
shellPath = /bin/sh;
shellScript = "
echo \"Remove signature files (Xcode workaround)\";
rm -rf \"$CONFIGURATION_BUILD_DIR/MapLibre.xcframework-ios.signature\";
";
};
A1D9EF7E0B4442DF8860F6A5 /* Fix Xcode 15 Bug */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
name = "Fix Xcode 15 Bug";
inputPaths = (
);
outputPaths = (
);
shellPath = /bin/sh;
shellScript = "if [ \"$XCODE_VERSION_MAJOR\" = \"1500\" ]; then
echo \"Remove signature files (Xcode 15 workaround)\"
find \"$BUILD_DIR/${CONFIGURATION}-iphoneos\" -name \"*.signature\" -type f | xargs -r rm
fi";
};
B6A277D5FA3848ECACDAF93C /* Remove signature files (Xcode workaround) */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
name = "Remove signature files (Xcode workaround)";
inputPaths = (
);
outputPaths = (
);
shellPath = /bin/sh;
shellScript = "
echo \"Remove signature files (Xcode workaround)\";
rm -rf \"$CONFIGURATION_BUILD_DIR/MapLibre.xcframework-ios.signature\";
"; ";
}; };
/* End PBXShellScriptBuildPhase section */ /* End PBXShellScriptBuildPhase section */

View file

@ -1,183 +1,183 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>BGTaskSchedulerPermittedIdentifiers</key> <key>BGTaskSchedulerPermittedIdentifiers</key>
<array> <array>
<string>com.transistorsoft</string> <string>com.transistorsoft</string>
<string>com.transistorsoft.fetch</string> <string>com.transistorsoft.fetch</string>
<string>com.transistorsoft.customtask</string> <string>com.transistorsoft.customtask</string>
</array> </array>
<key>CADisableMinimumFrameDurationOnPhone</key> <key>CADisableMinimumFrameDurationOnPhone</key>
<true/> <true/>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string> <string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleDisplayName</key> <key>CFBundleDisplayName</key>
<string>Alerte Secours</string> <string>Alerte Secours</string>
<key>CFBundleExecutable</key> <key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string> <string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key> <key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key> <key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string> <string>6.0</string>
<key>CFBundleName</key> <key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string> <string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string> <string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.16.0</string> <string>202601121722</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleURLTypes</key> <key>CFBundleURLTypes</key>
<array> <array>
<dict> <dict>
<key>CFBundleURLSchemes</key> <key>CFBundleURLName</key>
<array> <string>com.alertesecours.alertesecours</string>
<string>com.alertesecours.alertesecours</string> <key>CFBundleURLSchemes</key>
</array> <array>
<key>CFBundleURLName</key> <string>com.alertesecours.alertesecours</string>
<string>com.alertesecours.alertesecours</string> </array>
</dict> </dict>
<dict> <dict>
<key>CFBundleURLSchemes</key> <key>CFBundleURLName</key>
<array> <string>com.alertesecours.alertesecours.expo</string>
<string>exp+alerte-secours</string> <key>CFBundleURLSchemes</key>
</array> <array>
<key>CFBundleURLName</key> <string>exp+alerte-secours</string>
<string>com.alertesecours.alertesecours.expo</string> </array>
</dict> </dict>
</array> </array>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>231</string> <string>202601121722</string>
<key>ITSAppUsesNonExemptEncryption</key> <key>ITSAppUsesNonExemptEncryption</key>
<false/> <false/>
<key>LSApplicationQueriesSchemes</key> <key>LSApplicationQueriesSchemes</key>
<array> <array>
<string>http</string> <string>http</string>
<string>https</string> <string>https</string>
<string>comgooglemaps</string> <string>comgooglemaps</string>
<string>maps</string> <string>maps</string>
<string>waze</string> <string>waze</string>
<string>citymapper</string> <string>citymapper</string>
<string>uber</string> <string>uber</string>
<string>lyft</string> <string>lyft</string>
<string>transit</string> <string>transit</string>
<string>truckmap</string> <string>truckmap</string>
<string>waze-na</string> <string>waze-na</string>
<string>yandexnavi</string> <string>yandexnavi</string>
<string>moovit</string> <string>moovit</string>
<string>yandexmaps</string> <string>yandexmaps</string>
<string>kakaomap</string> <string>kakaomap</string>
<string>szn-mapy</string> <string>szn-mapy</string>
<string>mapsme</string> <string>mapsme</string>
<string>osmand</string> <string>osmand</string>
<string>gett</string> <string>gett</string>
<string>nmap</string> <string>nmap</string>
<string>dgis</string> <string>dgis</string>
<string>tel</string> <string>tel</string>
<string>telprompt</string> <string>telprompt</string>
<string>yandextaxi</string> <string>yandextaxi</string>
<string>tmap</string> <string>tmap</string>
<string>osmandmaps</string> <string>osmandmaps</string>
<string>lftgpas</string> <string>lftgpas</string>
<string>petalmaps</string> <string>petalmaps</string>
<string>sygic</string> <string>sygic</string>
</array> </array>
<key>LSMinimumSystemVersion</key> <key>LSMinimumSystemVersion</key>
<string>12.0</string> <string>12.0</string>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>
<true/> <true/>
<key>NSAppTransportSecurity</key> <key>NSAppTransportSecurity</key>
<dict> <dict>
<key>NSAllowsArbitraryLoads</key> <key>NSAllowsArbitraryLoads</key>
<false/> <false/>
<key>NSExceptionDomains</key> <key>NSExceptionDomains</key>
<dict> <dict>
<key>alertesecours.fr</key> <key>alertesecours.fr</key>
<dict> <dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key> <key>NSExceptionAllowsInsecureHTTPLoads</key>
<false/> <false/>
<key>NSExceptionMinimumTLSVersion</key> <key>NSExceptionMinimumTLSVersion</key>
<string>TLSv1.0</string> <string>TLSv1.0</string>
<key>NSExceptionRequiresForwardSecrecy</key> <key>NSExceptionRequiresForwardSecrecy</key>
<false/> <false/>
<key>NSIncludesSubdomains</key> <key>NSIncludesSubdomains</key>
<true/> <true/>
</dict> </dict>
<key>localhost</key> <key>localhost</key>
<dict> <dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key> <key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/> <true/>
<key>NSIncludesSubdomains</key> <key>NSIncludesSubdomains</key>
<true/> <true/>
</dict> </dict>
<key>sentry.io</key> <key>sentry.io</key>
<dict> <dict>
<key>NSExceptionMinimumTLSVersion</key> <key>NSExceptionMinimumTLSVersion</key>
<string>TLSv1.0</string> <string>TLSv1.0</string>
<key>NSExceptionRequiresForwardSecrecy</key> <key>NSExceptionRequiresForwardSecrecy</key>
<false/> <false/>
<key>NSIncludesSubdomains</key> <key>NSIncludesSubdomains</key>
<true/> <true/>
</dict> </dict>
</dict> </dict>
</dict> </dict>
<key>NSCameraUsageDescription</key> <key>NSCameraUsageDescription</key>
<string>Alerte-Secours requiert l'accès à votre caméra pour vous permettre de prendre une photo de profil. Cette fonctionnalité est utilisée uniquement lors de la personnalisation de votre compte.</string> <string>Alerte-Secours requiert l'accès à votre caméra pour vous permettre de prendre une photo de profil. Cette fonctionnalité est utilisée uniquement lors de la personnalisation de votre compte.</string>
<key>NSContactsUsageDescription</key> <key>NSContactsUsageDescription</key>
<string>Alerte-Secours demande l'accès à vos contacts pour afficher les noms associés aux numéros de téléphone. Ces informations restent strictement sur votre appareil et ne sont jamais partagées ni transmises à des tiers.</string> <string>Alerte-Secours demande l'accès à vos contacts pour afficher les noms associés aux numéros de téléphone. Ces informations restent strictement sur votre appareil et ne sont jamais partagées ni transmises à des tiers.</string>
<key>NSFaceIDUsageDescription</key> <key>NSFaceIDUsageDescription</key>
<string>Allow $(PRODUCT_NAME) to access your Face ID biometric data.</string> <string>Allow $(PRODUCT_NAME) to access your Face ID biometric data.</string>
<key>NSLocationAccuracyReduced</key> <key>NSLocationAccuracyReduced</key>
<string>Alerte-Secours nécessite une localisation précise pour optimiser l'assistance aux personnes en détresse. Cette précision est essentielle pour localiser efficacement et rejoindre rapidement les personnes ayant besoin d'aide.</string> <string>Alerte-Secours nécessite une localisation précise pour optimiser l'assistance aux personnes en détresse. Cette précision est essentielle pour localiser efficacement et rejoindre rapidement les personnes ayant besoin d'aide.</string>
<key>NSLocationAlwaysAndWhenInUseUsageDescription</key> <key>NSLocationAlwaysAndWhenInUseUsageDescription</key>
<string>Alerte-Secours nécessite la localisation en arrière-plan pour vous alerter en temps réel lorsqu'une personne à proximité a besoin d'aide urgente. Cette fonction est essentielle pour permettre une intervention rapide et efficace en cas d'urgence.</string> <string>Alerte-Secours nécessite la localisation en arrière-plan pour vous alerter en temps réel lorsqu'une personne à proximité a besoin d'aide urgente. Cette fonction est essentielle pour permettre une intervention rapide et efficace en cas d'urgence.</string>
<key>NSLocationAlwaysUsageDescription</key> <key>NSLocationAlwaysUsageDescription</key>
<string>[Alerte-Secours] Cette application nécessite l'accès à la localisation même en arrière-plan pour améliorer la sécurité et l'aide en cas d'urgence.</string> <string>[Alerte-Secours] Cette application nécessite l'accès à la localisation même en arrière-plan pour améliorer la sécurité et l'aide en cas d'urgence.</string>
<key>NSLocationWhenInUseUsageDescription</key> <key>NSLocationWhenInUseUsageDescription</key>
<string>Alerte-Secours utilise votre localisation pour identifier et vous diriger vers les personnes nécessitant une assistance à proximité. Cette fonction est cruciale pour une intervention rapide et précise en cas d'urgence.</string> <string>Alerte-Secours utilise votre localisation pour identifier et vous diriger vers les personnes nécessitant une assistance à proximité. Cette fonction est cruciale pour une intervention rapide et précise en cas d'urgence.</string>
<key>NSMicrophoneUsageDescription</key> <key>NSMicrophoneUsageDescription</key>
<string>Alerte-Secours requiert l'accès au microphone pour l'enregistrement de messages vocaux. Cette fonction permet une communication plus rapide et plus claire en situation d'urgence.</string> <string>Alerte-Secours requiert l'accès au microphone pour l'enregistrement de messages vocaux. Cette fonction permet une communication plus rapide et plus claire en situation d'urgence.</string>
<key>NSMotionUsageDescription</key> <key>NSMotionUsageDescription</key>
<string>Alerte-Secours utilise la détection de mouvement pour optimiser la géolocalisation en arrière-plan, réduisant ainsi la consommation de batterie. Aucune donnée de mouvement n'est stockée ni transmise.</string> <string>Alerte-Secours utilise la détection de mouvement pour optimiser la géolocalisation en arrière-plan, réduisant ainsi la consommation de batterie. Aucune donnée de mouvement n'est stockée ni transmise.</string>
<key>NSPhotoLibraryUsageDescription</key> <key>NSPhotoLibraryUsageDescription</key>
<string>Alerte-Secours demande l'accès à votre photothèque uniquement pour vous permettre de sélectionner une photo de profil. Cette fonctionnalité est utilisée exclusivement pour la personnalisation de votre compte.</string> <string>Alerte-Secours demande l'accès à votre photothèque uniquement pour vous permettre de sélectionner une photo de profil. Cette fonctionnalité est utilisée exclusivement pour la personnalisation de votre compte.</string>
<key>NSRemoteNotificationUsageDescription</key> <key>NSRemoteNotificationUsageDescription</key>
<string>[Alerte-Secours] Cette application utilise les notifications pour pouvoir vous prévenir lorsque quelqu'un a besoin d'aide à proximité</string> <string>[Alerte-Secours] Cette application utilise les notifications pour pouvoir vous prévenir lorsque quelqu'un a besoin d'aide à proximité</string>
<key>NSUserNotificationUsageDescription</key> <key>NSUserNotificationUsageDescription</key>
<string>Alerte-Secours utilise les notifications pour vous informer immédiatement lorsqu'une personne à proximité nécessite une assistance urgente. Ces alertes sont essentielles pour une réponse rapide aux situations d'urgence.</string> <string>Alerte-Secours utilise les notifications pour vous informer immédiatement lorsqu'une personne à proximité nécessite une assistance urgente. Ces alertes sont essentielles pour une réponse rapide aux situations d'urgence.</string>
<key>UIBackgroundModes</key> <key>UIBackgroundModes</key>
<array> <array>
<string>fetch</string> <string>fetch</string>
<string>location</string> <string>location</string>
<string>remote-notification</string> <string>remote-notification</string>
<string>processing</string> <string>processing</string>
</array> </array>
<key>UILaunchStoryboardName</key> <key>UILaunchStoryboardName</key>
<string>SplashScreen</string> <string>SplashScreen</string>
<key>UIRequiredDeviceCapabilities</key> <key>UIRequiredDeviceCapabilities</key>
<array> <array>
<string>arm64</string> <string>arm64</string>
</array> </array>
<key>UIRequiresFullScreen</key> <key>UIRequiresFullScreen</key>
<false/> <false/>
<key>UIStatusBarStyle</key> <key>UIStatusBarStyle</key>
<string>UIStatusBarStyleDefault</string> <string>UIStatusBarStyleDefault</string>
<key>UISupportedInterfaceOrientations</key> <key>UISupportedInterfaceOrientations</key>
<array> <array>
<string>UIInterfaceOrientationPortrait</string> <string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string> <string>UIInterfaceOrientationPortraitUpsideDown</string>
</array> </array>
<key>UISupportedInterfaceOrientations~ipad</key> <key>UISupportedInterfaceOrientations~ipad</key>
<array> <array>
<string>UIInterfaceOrientationPortrait</string> <string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string> <string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string> <string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string> <string>UIInterfaceOrientationLandscapeRight</string>
</array> </array>
<key>UIUserInterfaceStyle</key> <key>UIUserInterfaceStyle</key>
<string>Automatic</string> <string>Automatic</string>
<key>UIViewControllerBasedStatusBarAppearance</key> <key>UIViewControllerBasedStatusBarAppearance</key>
<false/> <false/>
</dict> </dict>
</plist> </plist>

View file

@ -52,19 +52,30 @@ fi
IPA_PLIST_TMP=$(mktemp -t as_ipa_Info.plist) IPA_PLIST_TMP=$(mktemp -t as_ipa_Info.plist)
unzip -p "$IPA_PATH" "Payload/AlerteSecours.app/Info.plist" > "$IPA_PLIST_TMP" 2>/dev/null || true unzip -p "$IPA_PATH" "Payload/AlerteSecours.app/Info.plist" > "$IPA_PLIST_TMP" 2>/dev/null || true
if [ -s "$IPA_PLIST_TMP" ]; then if [ -s "$IPA_PLIST_TMP" ]; then
IPA_PKG_VERSION=$(/usr/libexec/PlistBuddy -c "Print :CFBundleShortVersionString" "$IPA_PLIST_TMP" 2>/dev/null || echo "") IPA_PKG_VERSION=$(/usr/libexec/PlistBuddy -c "Print :CFBundleShortVersionString" "$IPA_PLIST_TMP" 2>/dev/null || echo "")
IPA_BUILD_NUMBER=$(/usr/libexec/PlistBuddy -c "Print :CFBundleVersion" "$IPA_PLIST_TMP" 2>/dev/null || echo "") IPA_BUILD_NUMBER=$(/usr/libexec/PlistBuddy -c "Print :CFBundleVersion" "$IPA_PLIST_TMP" 2>/dev/null || echo "")
echo " IPA Info.plist (from payload): ${IPA_PKG_VERSION:-unknown} (${IPA_BUILD_NUMBER:-unknown})" echo " IPA Info.plist (from payload): ${IPA_PKG_VERSION:-unknown} (${IPA_BUILD_NUMBER:-unknown})"
if [ -n "$IPA_PKG_VERSION" ] && [ -n "$IPA_BUILD_NUMBER" ]; then if [ -n "$IPA_PKG_VERSION" ] && [ -n "$IPA_BUILD_NUMBER" ]; then
if [ "$SRC_PKG_VERSION" != "$IPA_PKG_VERSION" ] || [ "$SRC_BUILD_NUMBER" != "$IPA_BUILD_NUMBER" ]; then # Enforce that CFBundleShortVersionString matches exactly between source and IPA.
echo "Error: IPA version mismatch with source Info.plist." if [ "$SRC_PKG_VERSION" != "$IPA_PKG_VERSION" ]; then
echo "Hint: Run 'yarn bundle:ios' to export a fresh IPA aligned with current versions." echo "Error: IPA CFBundleShortVersionString mismatch with source Info.plist."
rm -f "$IPA_PLIST_TMP" echo "Hint: Run 'yarn bundle:ios' to export a fresh IPA aligned with current versions."
exit 1 rm -f "$IPA_PLIST_TMP"
exit 1
fi
# Allow IPA CFBundleVersion to be greater than or equal to the source
# (Xcode may auto-increment it), but reject if it is lower, which
# indicates a stale IPA.
if [ "$IPA_BUILD_NUMBER" -lt "$SRC_BUILD_NUMBER" ]; then
echo "Error: IPA CFBundleVersion ($IPA_BUILD_NUMBER) is lower than source build number ($SRC_BUILD_NUMBER)."
echo "Hint: Run 'yarn bundle:ios' to export a fresh IPA aligned with current versions."
rm -f "$IPA_PLIST_TMP"
exit 1
fi
fi fi
fi else
else
echo "Warning: Could not read Info.plist from IPA payload for verification. Continuing." echo "Warning: Could not read Info.plist from IPA payload for verification. Continuing."
fi fi
rm -f "$IPA_PLIST_TMP" rm -f "$IPA_PLIST_TMP"