TextMate

TextMate is an excellent text editor for the Apple Mac.

It’s ideally suited to the agile web developer, and is very easy to extend with your scripting language of choice. It’s especially popular in the Ruby community, and is (credit where it’s due) the only reason that I switched from Linux to Macs several years ago.

TextMate is by no means the only editor worth investigating; I’m also a bit of a fan of Emacs, having used it for 10 years before I got TextMate. It’s just not as pretty. Or as easy to customise (but PeepCode can help you with that).

To learn more about TextMate you could do worse than to read the excellent TextMate Manual. I also highly recommend the Pragmatic Programmer’s book, TextMate: Power Editing for the Mac, which explains how to define your own snippets, macros and language grammars (get the PDF, save a tree – and some space on your desk).

Articles on TextMate

Opening Ruby gems in TextMate

How often do you find yourself wanting to check the source code of a locally installed Ruby gem? Do you find it painful digging around your filesystem to locate the gems directory?

Rather than this:

mate /Library/Ruby/Gems/1.8/gems/activerecord-2.0.2

I now type this:

mategem activerec[tab]

Note the tab key, which converts “activerecord” into “activerecord-2.0.2”.

Continue reading