Update: Pratik covers rails templates in more detail here.
I hate to use uber-superlatives, but this is just plain frakkin awesome to the power of a Chuck Norris roundhouse-kick: Jeremy McAnally‘s rg (don’t worry if you have no clue about rg – I heard about it 10 minutes ago myself (via Pratik)) made it to the rails core.
So what the hell is rg to begin with? rg is a rails generator, like the ‘rails’ command (the one used to create a blank Rails app) just way cooler. You think it has never been easier to create a skeleton app because we have bort? Well, then check this out:
(Eyes glazing over? Check it out (as well as other examples) on github).
It’s hard to believe, but the above template is able to generate a clean rails app which is basically bort (Or exactly bort. Or very similar to bort. Or similar to a bort lookalike. Or… I guess I leave this debate up to ruby lawyers, bort experts, rg zealots etc.) Anyway, it doesn’t really matter as rg was not invented to compete with bort – bort is merely used as an example because it’s probably the most popular Rails skeleton app nowadays – rg is far more general than that: an easy, concise, Rubyish way to describe your Rails app (including plugins, vendored gems, lib files, initializers and whatnot) in a very straightforward way.
There are a handful of base Rails apps out there – but the chance that one of them is *exactly* using the tools you are committed to is minimal. For example I prefer HAML to erb, SASS to CSS, jQuery to Prototype, somewhat undecided between Shoulda and rSpec, I’d like to give authlogic a spin the next time I need user authentication etc. and the list goes on and on – and it changes over time. With this addition to Rails this is no problem – it takes minutes to cook your own Rails skeleton app, and minutes to adjust it later.
If this is still not enough, check out the Jeremy’s TODO list: Save yourself the hassle of keeping your core components up to date (coming soon). OMG, I have been waiting for something like this for ages, and I doubt I am alone (though the ability to describe gems in environment.rb was a great leap forward) – this will really rock! Kudos Jeremy!