I needed a break yesterday and took a look at the newly released Beta 2 of Sublime Text 2. I had seen a little Twitter Chatter about it and I thought it would be a fun thing to look over as I tried to vent my brain a bit.
In a nutshell: it’s everything I love about Vim and Textmate, rolled into one. It doesn’t try to be a pretentious IDE, rather it stays committed to speedy text editing and file location. Finding files is incredibly easy and more intuitive then with TextMate, and it’s even easier than using Rails.vim with Vim.
I’m still a Vim fan – but when I flipped on “Vintage Mode” last night I almost fell out of my chair. All of the commands I’m used to in Vim (editing commands, that is) are there at the ready. Unreal – it’s Vim wrapped in some serious sex appeal – or the other way round it’s TextMate given a lot more smarts (and some much-needed UI flare).
And then there’s the automatic, intelligent code-completion thing. You get that with Supertab in Vim… but it’s always on in Sublime and it literally felt like intellisense in Visual Studio (but it’s based on words in the open windows, not types and properties).
The font rendering looks utterly lickable on a Mac. I mean seriously: I’ve never seen fonts so crisp and clean – all wrapped up in a lightning fast editor UI.
I’m quite taken with Sublime, and it’s surprising to me. I’m a bit of an Old Dog when it comes to my tools – I tend to like things “just so” (as opposed to playing with languages and frameworks). I was utterly surprised when, after 45 minutes or so of goofing around and getting things setup – I decided that Beta or not I was going to buy this thing and switch right over.
Sublime will work with all of your TextMate bundles – so you have everything at the ready, right now! It comes with some great themes (typical Blackboard from TextMate – but I settled for Twilight) and there’s already a fleet of plugins ready to go.
Finally – this is a killer feature: multiple selection and edit. Select a word in your file using Cmd-D. Hit Cmd-D again and Sublime will highlight the next instance of that word. Start typing – multiple cursors show up and you’re now editing all of the instances of your selected word.
Give it a whirl – it’s Friday, have some fun!
Tips
Here’s some tips to get you up to speed quickly:
Setup your console. If you launch Sublime from the console it’s much easier to get many of the plugins working. You can do this by using the following command:
ln -s "/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl" /usr/local/bin
This command will add a symbolic link to your path for Sublime – so you can open it up from the console using the command “subl”.
Add Sublime Package Control. This amazing little plugin will let you search for plugins and install them just like any package manager would (npm, rubygems, nuget, apt). Need something to execute RSpec tasks with a simple command? Shift-Cmd-P brings up the Finder, “Install” brings up the Package Control UI. Enter the package you want, hit enter, and you’re off. Incredibly simple.
Get to know the basic commands. If you’re familiar with TextMate – then most everything is what you expect, with a few exceptions. Cmd-T opens a new tab (but also let’s you search for a file) but selecting a block of text and using TAB will indent it (just like VS). SHIFT-TAB will outdent. Option-Cmd 1, 2, and 3 will split the window into 1, 2 and 3 columns. I could fill this up with key commands but I’ll leave it here. There’s a lot to explore.
Distraction Free Mode. Give it a whirl. It looks amazing on a dual monitor system and you tend to get a lot of work done
.
Font changes. I like Monaco, mostly because I’m used to it. I didn’t care for the default font so I changed it in Preferences/File Settings – User (or Cmd-,). It’s a JSON file and you simply want to add the like “font_face”: “Monaco” (or whatever). The UI will change instantly, which is nice.
I’m sure I’ve missed a few things – leave a comment with whatever I’ve left out.

