Skip to content

Instantly share code, notes, and snippets.

@inkdeep
Created April 7, 2011 17:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save inkdeep/908283 to your computer and use it in GitHub Desktop.
Save inkdeep/908283 to your computer and use it in GitHub Desktop.
Update TextMate bundles cloned from GitHub (or wherever) in ~/Library/Application Support/TextMate/Bundles
#!/usr/bin/env ruby
textmate_bundle_path = File.expand_path('~/Library/Application Support/TextMate/Bundles/')
Dir.chdir(textmate_bundle_path)
bundles = Dir.glob('*.tmbundle')
bundles.each do |bundle|
Dir.chdir(File.join(textmate_bundle_path, bundle))
puts %(
------------------------------------------
Updating #{bundle}
------------------------------------------
)
if File.directory?('.git')
result = `git pull`
puts result
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment