Skip to content

Instantly share code, notes, and snippets.

@TheCodeEngine
Created May 26, 2013 11:27
Show Gist options
  • Save TheCodeEngine/5652522 to your computer and use it in GitHub Desktop.
Save TheCodeEngine/5652522 to your computer and use it in GitHub Desktop.
XCode 4 Build Number from git Reposotory
#!/bin/bash
buildNumber=`git rev-list HEAD | head -c5`
/usr/libexec/PlistBuddy -c "Set :CFBundleVersion $buildNumber" "$INFOPLIST_FILE"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment