Friday, December 5, 2014

Putting Groovy on Mint (and other Linux distros) the easy way

Installing Groovy on any Linux distro is a pain in the ass. Generally, the procedure is:

  1. Install the requisites. This could be an involved process because you could be potentially install a lot of stuff but at minimum just need Java.
  2. Download the binaries for groovy. If your Linux distro has a repo like Debian, I don't recommend using it because it not the latest.
  3. Do a bit of file handling and doing a bunch of sym links to the binaries.
  4. Configure your bash shell for groovy. Just like step 3, not fun and just plain tedious.
Fortunately for me, I've found a much easier way to do these steps with GVM. GVM is a tool for managing parallel Versions of multiple Software Development Kits on most Unix based systems. Inspired by Ruby's RVM, it's a convenient command line interface for installing, switching, removing and listing Groovy libraries. GVM call these libraries as candidates.

Just do this to install GVM:

curl -s | bash

And then do this to install Groovy.

gvm install groovy

That should install the latest version of groovy and we're off and running with groovy development.