Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save alessandrostone/26989067af3a4b072820086d79c3f940 to your computer and use it in GitHub Desktop.
Save alessandrostone/26989067af3a4b072820086d79c3f940 to your computer and use it in GitHub Desktop.
Xcode Increment Build Run Phase Script
buildNumber=$(/usr/libexec/PlistBuddy -c "Print CFBundleVersion" "${PROJECT_DIR}/${INFOPLIST_FILE}")
buildNumber=$(($buildNumber + 1))
/usr/libexec/PlistBuddy -c "Set :CFBundleVersion $buildNumber" "${PROJECT_DIR}/${INFOPLIST_FILE}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment