Textmate gem

As I said last week, I created thor while building a binary to handle my textmate bundles.

I wanted a way to install/uninstall/list textmate bundles like gems. Textmate already has a centralized svn repository for its bundles, and there's a way, through AppleScript, to tell Textmate to reload bundles. The end result: a textmate binary that handles textmate bundles like gems.

$ textmate remote

``` Marcomates Trunk Remote Bundles ------------------------------- ANTLR ASP ASP_vb_NET ActionScript Active4D Ada Apache AppleScript Bison Blogging Bulletin Board Bundle Development C++ Qt C CSS CTags CVS ColdFusion Context Free D Darcs ... snip ... ```

$ textmate remote JavaScript

``` Marcomates Trunk Remote Bundles ------------------------------- JavaScript MooTools JavaScript Prototype & Script_aculo_us JavaScript YUI JavaScript jQuery JavaScript

Marcomates Review Remote Bundles

JavaScript JSDoc
JavaScript MooTools
JavaScript Prototype & Script_aculo_us
JavaScript


<h4>$ textmate list</h4>

Application Bundles

ActionScript
Apache
AppleScript
Blogging
Bundle Development
C
CSS
... snip ...
User Pristine Bundles

User Bundles

RSpec
Ruby Haml
Ruby Sass
Ruby
Rucola
Treetop

System Pristine Bundles

System Bundles

Ragel


<h4>$ textmate install</h4>
Checking out JavaScript jQuery...
svn co http\://macromates.com/svn/Bundles/trunk/Bundles/JavaScript\ jQuery.tmbundle /Users/wycats/Library/Application\ Support/TextMate/Pristine\ Copy/JavaScript\ jQuery.tmbundle 2>&1
    A    /Users/wycats/Library/Application Support/TextMate/Pristine Copy/JavaScript jQuery.tmbundle/Commands
    A    /Users/wycats/Library/Application Support/TextMate/Pristine Copy/JavaScript jQuery.tmbundle/Commands/Documentation for Word : Selection.tmCommand
    A    /Users/wycats/Library/Application Support/TextMate/Pristine Copy/JavaScript jQuery.tmbundle/Snippets
    A    /Users/wycats/Library/Application Support/TextMate/Pristine Copy/JavaScript jQuery.tmbundle/Snippets/each.tmSnippet
    A    /Users/wycats/Library/Application Support/TextMate/Pristine Copy/JavaScript jQuery.tmbundle/Snippets/clone.tmSnippet
... snip ...
    Checked out revision 9623.
Reloading Bundles...
Done.
</pre>

<h4>$ textmate uninstall "JavaScript Prototype & Script_aculo_us"</h4>

Removing bundle...
Reloading bundles...
Done.


Pretty cool, huh? If you want it, do <code>gem install wycats-textmate --source http://gems.github.com</code>.
Show Comments