Created
July 14, 2014 15:42
-
-
Save ijansch/187845faf6aea780fb99 to your computer and use it in GitHub Desktop.
Including the buildozer build number in an app
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
buildVersion=$(/usr/libexec/PlistBuddy -c "Print CFBundleShortVersionString" "$INFOPLIST_FILE") | |
if [ -n "$BUILDOZER_BUILDNUMBER" ]; then | |
buildNumber=$BUILDOZER_BUILDNUMBER | |
else | |
buildNumber="dev" | |
fi | |
/usr/libexec/PlistBuddy -c "Set :CFBundleVersion $buildVersion.$buildNumber" "$INFOPLIST_FILE" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You'd place this in a 'run script' build phase. (mind the order, it must update the plist before it actually builds the app).