Recently I needed to do some static HTML stuff and wanted to use Haml for this. LiveReload, which I’m using since quite some time, lets you setup watchfolders and compiles all kinds of stuff for you like CoffeeScript, LESS, Sass and Haml. Unfortunately it would only accept the hash syntax used in ruby prior 1.9 and that’s because LiveReload uses my system ruby by default, which is 1.8.7.
1 2 3 | |
It gives you the option to switch to another ruby version, but doesn’t support installations via rbenv (it will probably be introduced in version 3 of LiveReload). I read somewhere that RVM is supported, but I can’t validate this.
Long story short, I needed a different compiler to take advantage of the new syntax. Since I like the watchfolder simplicity of LiveReload, I took a look at CodeKit. From what I can say right now is, on the compiler end it does basically the same thing as LiveReload (please correct me if I’m wrong, I’m only using it for like 5 seconds), but offers a bit more flexibility when choosing your compiler. In my case I just went into the settings for Haml and pointed to the Haml binary inside my latest ruby installation (~/.rbenv/versions/1.9.3-p194/bin/haml), et voilĂ : Ruby 1.9 syntax in Haml.
