E: me@sabisin.com | T: +49.151.68651209

Increase the build number while Archiving in Xcode

Here are steps how to set it up :

1. Click on the project name in left side panel
2. Go to TARGETS and select your base project
3. Click on build phases tab on the top right side

Part of Xcode will look like this

Copy this entire script in the provided blank space.

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}"

Leave a Reply