This time I'm going to show you how to install and setup Grails on leopard. If this post looks simular to the groovy post, then thats because the method for installing the two are very simular, and I have a cut and paste button, and imm feeling lazy.
First make sure you have java and its dev tools setup on your machine see this post on how to do that.
Now download grails from the grails site.
Unpack the archive and move it to /usr/share , for example:
$ sudo mv ~/downloads/grails-1.0.1 /usr/share
Now set ownership and permissions on the directories
$sudo chown -R root:wheel grails-1.0.1/
$sudo chmod 0755 grails-1.0.1/bin/*
Now create a symlink to access the current version of grails by, if you download and install another version later, you can just move the symlink to point at it, this is a good practice as it prevents you having to overwrite your old installation.
$ln -s grails-1.0.1 grails
Finaly add the following to your /etc/profile or ~/.profile depending on wether you want it available for all logons or just your own.
GRAILS_HOME=/usr/share/grails; export GRAILS_HOME
And the following to your path in the same file, note your path should be defined after the above
PATH = $GRAILS_HOME/bin:$PATH; export PATH
Now your ready to try it out and see if it works, open up a terminal and type:
Welcome to Grails 1.0.1 - http://grails.org/
Licensed under Apache Standard License 2.0
Grails home is set to: /usr/share/grails
No script name specified. Use 'grails help' for more info
Cool, it works.