Java Reference
In-Depth Information
On Macs or Unix flavors, the same settings are
$ export JAVA_HOME=/Library/Java/...
$ export PATH=$PATH:$JAVA_HOME/bin
There are too many variations on these statements to count, depending on directory struc-
ture and version numbers, but the principles are always the same: install Java, set the
JAVA_HOME variable to point to it, and add its bin subdirectory to your path.
A.2. Installing Groovy
Assuming you've installed Java, installing Groovyis easy.Again, there are several options,
but the basic process comes down to downloading and unzipping the distribution, setting a
GROOVY_HOME environment variable, and adding its bin subdirectory to your path.
If you're not a fan of automated installers or you don't have root privileges on your ma-
chine, you can download a zipped, binary distribution of Groovy directly. The current ver-
sion can always be found at http://groovy.codehaus.org/Download . You can get either the
binary release or the source release (or both). Either way, unzip the download into a direct-
ory of your choice.
On Windows, following the same pattern as the Java installation, it's
C:\> set GROOVY_HOME=C:\Groovy\groovy-2.1.6
C:\> set PATH=%GROOVY_HOME%\bin;%PATH%
On a Mac or Unix, the same process is
$ export GROOVY_HOME=...
$ export PATH=$PATH:$GROOVY_HOME/bin
Ifyoudon'tmindinstallers,agoodoneisavailableforWindows.AnEXEinstallerisavail-
able on the same download page, which will install Groovy to a directory of your choice,
set the GROOVY_HOME variable for you, and add the bin folder underneath it to your path.
It also offers to install some optional libraries for you, which are useful and do not interfere
with your regular installation in any way. I've been using the Windows installer at client
Search WWH ::




Custom Search