Having converted the customer-facing pages of Wotif.com from a Freemarker/WebWork/EJB stack to a Grails/Spring3 stack earlier this year, I’m now officially a huge Grails fan. In setting up a new dev box, I wanted to install it – but who wants to install a download, huh? I wanted to build it from source (you can tell I’m a former Gentoo user!). Here’s what I did.
- Clone the Git repository: git clone git://github.com/grails/grails-core.git
- Checkout the version tag to install: git checkout tags/v2.0.0.M2
- Add the checkout as an environment variable – $GRAILS_HOME
- Add ${GRAILS_HOME}/bin to my path
- Build the app – ./gradlew install
These steps all courtesy of the Grails developer documentation – except the last bit. It’s changed with v2.
On a more serious question: why build it from source? Well, this is for a milestone build, after all – there may be bugs, and having the source handy could be useful. Also, being Git, if I want to patch it, I can share those patches easily via GitHub. And finally, why not?