Many thanks Jon!
Setting up an environment variable GROOVY_HOME by adding it into ~/.bashrc works perfectly for me. An alternative, following a helpful post by Dushan Basnayake on 1 June at http://dushan888.wordpress.com/2012/06/ ... inux-mint/
is to add the environment variable to /etc/bash.bashrc in superuser mode, which also works.
Personally I like to have separate partitions for root and my home folder, in the hope that when updating to later operating system versions the variables and PATH I have set up may not have to be changed, so I prefer your solution of using ~/.bashrc . Thanks for your help.
Incidentally, for anyone treading the same paths, pay no attention to the instruction in ~/.profile which says "see /usr/share/doc/bash/examples/startup-files for examples", as that directory doesn't exist!