Skip to content

Commit

Permalink
Wasn't working with XCode 3.1.2 / Leopard; added explicit Foundation.…
Browse files Browse the repository at this point in the history
…framework requirement, updated writeToFile message.

Signed-off-by: elliottcable <github.com@elliottcable.com>
  • Loading branch information
wajiii authored and ELLIOTTCABLE committed Apr 3, 2009
1 parent 8c04ec2 commit 2c677fe
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion xcode-git-versioner.rb
@@ -1,3 +1,8 @@
# per: http://rubycocoa.sourceforge.net/RequireFramework
require 'osx/cocoa'
include OSX
OSX.require_framework 'Foundation'

RunOnlyOnRelease = false RunOnlyOnRelease = false


raise "Must be run from Xcode" unless ENV['XCODE_VERSION_ACTUAL'] raise "Must be run from Xcode" unless ENV['XCODE_VERSION_ACTUAL']
Expand All @@ -16,6 +21,6 @@


list = NSMutableDictionary.dictionaryWithContentsOfFile plist list = NSMutableDictionary.dictionaryWithContentsOfFile plist
list['CFBundleVersion'] = version list['CFBundleVersion'] = version
list.writeToFile plist, :atomically => true list.objc_send(:writeToFile, plist, :atomically, true)


puts "CFBundleVersion set to '#{version}'!" puts "CFBundleVersion set to '#{version}'!"

0 comments on commit 2c677fe

Please sign in to comment.