There is currently a TextMate bundle in process for the templating language, Haml. It doesn’t come built-in, however. Installation is fairly simple once you figure it out.
(Keep in mind, my TextMate application location may vary from yours. This is simply what I found works for me.)
First, browse to your bundles area in Terminal.
Then check out the TextMate bundle from MacroMates’ bundle repository:
Then, reload your bundles in TextMate (Bundles | Bundle Editor | Reload Bundles).
Finally, for some reason tabbing isn’t set properly by default when editing a Haml file, which is important for this white-space-aware templating language. Perhaps the expectation is that you will always use your space bar? In any case, after opening a .haml file, look along the bottom bar of the TextMate interface. Be sure the Haml bundle is selected, and change your tabbing to Soft Tabs at 2 spaces per tab.

Update: Here are instructions for installing the Sass TextMate bundle:
svn co "http://macromates.com/svn/Bundles/trunk/Review/Bundles/Ruby Sass.tmbundle"
For both the Haml and Sass bundles, you may prefer to install the bundles in your “personalized” bundle area. Simply replace the cd commands above with:







Comments (13)
Fantastic. I already had the bundle installed, but I just hadn’t realised that tabbing could be changed that easily.
I had to checkout with the following url:
svn co “http://macromates.com/svn/Bundles/trunk/Bundles/Ruby Haml.tmbundle”
I see the Ruby Haml. tmbundle but when I try it, I get:
svn: URL ‘http://macromates.com/svn/Bundles/trunk/Bundles/Haml.tmbundle’ doesn’t exist
Is the space causing the issue? Thanks.
Oops…forgot to add the quotes. Thanks.
Fantastic. Haml away everyone!
For clarity, please update the article to reflect the new url:
http://macromates.com/svn/Bundles/trunk/Bundles/Ruby%20Haml.tmbundle/
There’s an easier way :)
sudo gem install bundlemate
bundlemate install “Ruby Haml”
bundlemate install “Ruby Sass”
:)
Worked perfect.
Color changes everything!
Arrgh. What happened to the Sass bundle?
“The requested URL /svn/Bundles/trunk/Bundles/Ruby Sass.tmbundle was not found on this server.”
That stinks, Jeff. It indeed appears to be gone.
Aussiegeek’s github project looks like a promising mirror.
The Sass bundle is in the Review section:
Watch out for those fancy quotes.
Thanks, Henrik. I’ve updated the post with the new bundle location.
Trackback/Pingback (1)
[...] å¯ä»¥å‚考下这篇blog [...]