Skip to content

Instantly share code, notes, and snippets.

@catesandrew
Created April 25, 2011 23:28
Show Gist options
  • Save catesandrew/941479 to your computer and use it in GitHub Desktop.
Save catesandrew/941479 to your computer and use it in GitHub Desktop.
update textmate plugins and bundles
#!/usr/bin/env bash
### Exists? Check
if [[ ! -e /Users/`whoami`/Library/Application\ Support/TextMate/Pristine\ Copy/Bundles ]]; then
mkdir /Users/`whoami`/Library/Application\ Support/TextMate/Pristine\ Copy/Bundles
fi
if [[ ! -e /Users/`whoami`/Library/Application\ Support/TextMate/Plugins ]]; then
mkdir /Users/`whoami`/Library/Application\ Support/TextMate/Plugins
fi
#
# This script will install the following Textmate bundles
#
# Languages
# - c https://github.com/textmate/c.tmbundle
# - coffeescript https://github.com/jashkenas/coffee-script-tmbundle
# - context free https://github.com/textmate/context-free.tmbundle
# - css https://github.com/textmate/css.tmbundle
# - erlang https://github.com/textmate/erlang.tmbundle
# - haskell https://github.com/textmate/haskell.tmbundle.git
# - html https://github.com/textmate/html.tmbundle
# - java https://github.com/textmate/java.tmbundle
# - javascript https://github.com/subtleGradient/javascript.tmbundle
# - json https://github.com/textmate/json.tmbundle
# - latex https://github.com/textmate/latex.tmbundle
# - lisp https://github.com/textmate/lisp.tmbundle.git
# - markdown https://github.com/textmate/markdown.tmbundle
# - objective-c https://github.com/textmate/objective-c.tmbundle
# - python https://github.com/textmate/python.tmbundle
# - ruby https://github.com/textmate/ruby.tmbundle
# - scala https://github.com/mads379/scala.tmbundle
# - scss https://github.com/kuroir/SCSS.tmbundle
# - shell https://github.com/textmate/shellscript.tmbundle
# - standard-ml https://github.com/textmate/standard-ml.tmbundle
# - textile https://github.com/textmate/textile.tmbundle
# - xml https://github.com/textmate/xml.tmbundle
# - yaml https://github.com/textmate/yaml.tmbundle
#
# Utilities
# - navigation https://github.com/textmate/navigation.tmbundle
# - git https://github.com/jcf/git-tmbundle
# - tidy https://github.com/mads379/tidy.tmbundle
# - js-tools https://github.com/adamhope/js-tools.tmbundle
# - ensime https://github.com/mads379/ensime.tmbundle
# - diff https://github.com/textmate/diff.tmbundle
#
# Plugins I use but this script won't install
# - missing drawer https://github.com/jezdez/textmate-missingdrawer
### Bundles
cd /Users/`whoami`/Library/Application\ Support/TextMate/Pristine\ Copy/Bundles
echo "----------------------"
echo "Installing languages."
echo "----------------------"
if [ ! -d Erlang.tmbundle ]
then
git clone https://github.com/textmate/erlang.tmbundle.git Erlang.tmbundle
fi
cd Erlang.tmbundle
git pull
cd ..
if [ ! -d Lisp.tmbundle ]
then
git clone https://github.com/textmate/lisp.tmbundle.git Lisp.tmbundle
fi
cd Lisp.tmbundle
git pull
cd ..
if [ ! -d Haskell.tmbundle ]
then
git clone https://github.com/textmate/haskell.tmbundle.git Haskell.tmbundle
fi
cd Haskell.tmbundle
git pull
cd ..
if [ ! -d JavaScript.tmbundle ]
then
git clone https://github.com/subtleGradient/javascript.tmbundle.git JavaScript.tmbundle
fi
cd JavaScript.tmbundle
git pull
cd ..
if [ ! -d Scala.tmbundle ]
then
git clone https://github.com/mads379/scala.tmbundle.git Scala.tmbundle
fi
cd Scala.tmbundle
git pull
cd ..
if [ ! -d CoffeScript.tmbundle ]
then
git clone https://github.com/jashkenas/coffee-script-tmbundle.git CoffeScript.tmbundle
fi
cd CoffeScript.tmbundle
git pull
cd ..
if [ ! -d ContextFree.tmbundle ]
then
git clone https://github.com/textmate/context-free.tmbundle.git ContextFree.tmbundle
fi
cd ContextFree.tmbundle
git pull
cd ..
if [ ! -d SCSS.tmbundle ]
then
git clone https://github.com/kuroir/SCSS.tmbundle.git SCSS.tmbundle
fi
cd SCSS.tmbundle
git pull
cd ..
if [ ! -d Objective-C.tmbundle ]
then
git clone https://github.com/textmate/objective-c.tmbundle.git Objective-C.tmbundle
fi
cd Objective-C.tmbundle
git pull
cd ..
if [ ! -d Ruby.tmbundle ]
then
git clone https://github.com/textmate/ruby.tmbundle.git Ruby.tmbundle
fi
cd Ruby.tmbundle
git pull
cd ..
if [ ! -d Java.tmbundle ]
then
git clone https://github.com/textmate/java.tmbundle.git Java.tmbundle
fi
cd Java.tmbundle
git pull
cd ..
if [ ! -d Markdown.tmbundle ]
then
git clone https://github.com/textmate/markdown.tmbundle.git Markdown.tmbundle
fi
cd Markdown.tmbundle
git pull
cd ..
if [ ! -d Python.tmbundle ]
then
git clone https://github.com/textmate/python.tmbundle.git Python.tmbundle
fi
cd Python.tmbundle
git pull
cd ..
if [ ! -d LaTeX.tmbundle ]
then
git clone https://github.com/textmate/latex.tmbundle.git LaTeX.tmbundle
fi
cd LaTeX.tmbundle
git pull
cd ..
if [ ! -d C.tmbundle ]
then
git clone https://github.com/textmate/c.tmbundle.git C.tmbundle
fi
cd C.tmbundle
git pull
cd ..
if [ ! -d XML.tmbundle ]
then
git clone https://github.com/textmate/xml.tmbundle.git XML.tmbundle
fi
cd XML.tmbundle
git pull
cd ..
if [ ! -d JSON.tmbundle ]
then
git clone https://github.com/textmate/json.tmbundle.git JSON.tmbundle
fi
cd JSON.tmbundle
git pull
cd ..
if [ ! -d ShellScript.tmbundle ]
then
git clone https://github.com/textmate/shellscript.tmbundle.git ShellScript.tmbundle
fi
cd ShellScript.tmbundle
git pull
cd ..
if [ ! -d Textile.tmbundle ]
then
git clone https://github.com/textmate/textile.tmbundle.git Textile.tmbundle
fi
cd Textile.tmbundle
git pull
cd ..
if [ ! -d StandardML.tmbundle ]
then
git clone https://github.com/textmate/standard-ml.tmbundle.git StandardML.tmbundle
fi
cd StandardML.tmbundle
git pull
cd ..
if [ ! -d YAML.tmbundle ]
then
git clone https://github.com/textmate/yaml.tmbundle.git YAML.tmbundle
fi
cd YAML.tmbundle
git pull
cd ..
if [ ! -d HTML.tmbundle ]
then
git clone https://github.com/textmate/html.tmbundle.git HTML.tmbundle
fi
cd HTML.tmbundle
git pull
cd ..
if [ ! -d CSS.tmbundle ]
then
git clone https://github.com/textmate/css.tmbundle.git CSS.tmbundle
fi
cd CSS.tmbundle
git pull
cd ..
if [ ! -d ExtendScript.tmbundle ]
then
git clone https://github.com/milligramme/extendscript-tmbundle.git ExtendScript.tmbundle
fi
cd ExtendScript.tmbundle
git pull
cd ..
if [ ! -d JsDocToolkit.tmbundle ]
then
git clone https://github.com/choan/jsdoctoolkit-tmbundle.git JsDocToolkit.tmbundle
fi
cd JsDocToolkit.tmbundle
git pull
cd ..
if [ ! -d AppleScript.tmbundle ]
then
git clone https://github.com/textmate/applescript.tmbundle.git AppleScript.tmbundle
fi
cd AppleScript.tmbundle
git pull
cd ..
if [ ! -d HTML5.tmbundle ]
then
git clone https://github.com/johnmuhl/html5.tmbundle.git HTML5.tmbundle
fi
cd HTML5.tmbundle
git pull
cd ..
if [ ! -d HAML-Handcrafted.tmbundle ]
then
git clone https://github.com/handcrafted/handcrafted-haml-textmate-bundle.git HAML-Handcrafted.tmbundle
fi
cd HAML-Handcrafted.tmbundle
git pull
cd ..
if [ ! -d RSpec.tmbundle ]
then
git clone https://github.com/rspec/rspec-tmbundle.git RSpec.tmbundle
fi
cd RSpec.tmbundle
git pull
cd ..
if [ ! -d RDoc.tmbundle ]
then
git clone https://github.com/joshaven/RDoc.tmbundle.git RDoc.tmbundle
fi
cd RDoc.tmbundle
git pull
cd ..
if [ ! -d Processing.tmbundle ]
then
git clone https://github.com/peon/Processing.tmbundle.git Processing.tmbundle
fi
cd Processing.tmbundle
git pull
cd ..
if [ ! -d Groovy.tmbundle ]
then
git clone https://github.com/textmate/groovy.tmbundle.git Groovy.tmbundle
fi
cd Groovy.tmbundle
git pull
cd ..
if [ ! -d jQuery.tmbundle ]
then
git clone https://github.com/textmate/javascript-jquery.tmbundle jQuery.tmbundle
fi
cd jQuery.tmbundle
git pull
cd ..
if [ ! -d Perforce.tmbundle ]
then
git clone https://github.com/textmate/perforce.tmbundle.git Perforce.tmbundle
fi
cd Perforce.tmbundle
git pull
cd ..
if [ ! -d Antlr.tmbundle ]
then
git clone https://github.com/textmate/antlr.tmbundle.git Antlr.tmbundle
fi
cd Antlr.tmbundle
git pull
cd ..
if [ ! -d ant.tmbundle ]
then
git clone https://github.com/textmate/ant.tmbundle.git ant.tmbundle
fi
cd ant.tmbundle
git pull
cd ..
if [ ! -d Apache.tmbundle ]
then
git clone https://github.com/textmate/apache.tmbundle.git Apache.tmbundle
fi
cd Apache.tmbundle
git pull
cd ..
if [ ! -d Source.tmbundle ]
then
git clone https://github.com/textmate/source.tmbundle.git Source.tmbundle
fi
cd Source.tmbundle
git pull
cd ..
if [ ! -d Subversion.tmbundle ]
then
git clone https://github.com/textmate/subversion.tmbundle.git Subversion.tmbundle
fi
cd Subversion.tmbundle
git pull
cd ..
if [ ! -d TODO.tmbundle ]
then
git clone https://github.com/textmate/todo.tmbundle.git TODO.tmbundle
fi
cd TODO.tmbundle
git pull
cd ..
if [ ! -d TextMate.tmbundle ]
then
git clone https://github.com/textmate/textmate.tmbundle.git TextMate.tmbundle
fi
cd TextMate.tmbundle
git pull
cd ..
if [ ! -d CSSExtended.tmbundle ]
then
git clone https://github.com/gordonbrander/css-extended.tmbundle.git CSSExtended.tmbundle
fi
cd CSSExtended.tmbundle
git pull
cd ..
if [ ! -d CSSDOC.tmbundle ]
then
git clone https://github.com/gordonbrander/CSSDOC.tmbundle.git CSSDOC.tmbundle
fi
cd CSSDOC.tmbundle
git pull
cd ..
if [ ! -d NodeJS.tmbundle ]
then
git clone https://github.com/drnic/javascript-node.tmbundle.git NodeJS.tmbundle
fi
cd NodeJS.tmbundle
git pull
cd ..
echo "----------------------"
echo "Installing utilities."
echo "----------------------"
if [ ! -d Git.tmbundle ]
then
git clone https://github.com/jcf/git-tmbundle.git Git.tmbundle
fi
cd Git.tmbundle
git pull
cd ..
if [ ! -d JSTools.tmbundle ]
then
git clone https://github.com/adamhope/js-tools.tmbundle.git JSTools.tmbundle
fi
cd JSTools.tmbundle
git pull
cd ..
if [ ! -d Ensime.tmbundle ]
then
git clone https://github.com/mads379/ensime.tmbundle.git Ensime.tmbundle
fi
cd Ensime.tmbundle
git pull
cd ..
if [ ! -d Tidy.tmbundle ]
then
git clone https://github.com/mads379/tidy.tmbundle.git Tidy.tmbundle
fi
cd Tidy.tmbundle
git pull
cd ..
if [ ! -d Navigation.tmbundle ]
then
git clone https://github.com/textmate/navigation.tmbundle.git Navigation.tmbundle
fi
cd Navigation.tmbundle
git pull
cd ..
if [ ! -d Diff.tmbundle ]
then
git clone https://github.com/textmate/diff.tmbundle.git Diff.tmbundle
fi
cd Diff.tmbundle
git pull
cd ..
if [ ! -d txt2tags.tmbundle ]
then
git clone https://github.com/textmate/txt2tags.tmbundle.git txt2tags.tmbundle
fi
cd txt2tags.tmbundle
git pull
cd ..
if [ -d Mustache.tmbundle ]
then
rm -Rf Mustache.tmbundle
fi
git clone https://github.com/defunkt/Mustache.tmbundle.git Mustache
mv ./Mustache/Mustache.tmbundle/ ./Mustache.tmbundle
rm -Rf Mustache
echo "----------------------"
echo "Installing plugins."
echo "----------------------"
### Plugins
cd /Users/`whoami`/Library/Application\ Support/TextMate/PlugIns
# MissingDrawer Plugin for TextMate
#if [ ! -d MissingDrawer.tmplugin ]
#then
#git clone git://github.com/jezdez/textmate-missingdrawer.git MissingDrawer.tmplugin
#fi
#cd MissingDrawer.tmplugin
#git pull
#cd ..
# AckMate for TextMate
#if [ ! -d AckMate.tmplugin ]
#then
#git clone git://github.com/protocool/AckMate.git AckMate.tmplugin
#fi
#cd AckMate.tmplugin
#git pull
#cd ..
osascript -e 'tell app "TextMate" to reload bundles'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment