Skip to content

Instantly share code, notes, and snippets.

@TBonnin
TBonnin / gist:2828203
Created May 29, 2012 12:46 — forked from mdales/gist:2622886
Updating Xcode project version number from git
# Use git describe as build number
echo "Updating version/build number from git..."
plist=${PROJECT_DIR}/${INFOPLIST_FILE}
# Get build/version number
versionnum=`git describe --tags | awk '{split($0,a,"-"); print a[1]}'`
buildnum=`git describe --tags`
if [[ "${versionnum}" == "" ]]; then