Skip to content

Instantly share code, notes, and snippets.

@hSATAC
Created May 25, 2012 04:42
Show Gist options
  • Select an option

  • Save hSATAC/2785809 to your computer and use it in GitHub Desktop.

Select an option

Save hSATAC/2785809 to your computer and use it in GitHub Desktop.
set git rev as xcode bundle version
#!/usr/bin/env ruby
plist = "/Users/cat/projects/proj/proj-Info.plist"
version = `git rev-parse --short HEAD`
`/usr/libexec/Plistbuddy -c "Set CFBundleVersion #{version}" #{plist}`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment