What follows is a summary of the commands in a tutorial i followed to start using Groovy on grails.
Create Groovy app
> cd ~/workspace/
> mkdir mywebsite
> grails create-app mywebsite
Note that you’ll end up with a double directory; mywebsite/mywebsite
This is my preferred folder structure for most projects. It allows me to keep other website related assets under the same “title” but not as part of the actual website itself.
Test app for first time
>cd mywebsite
>grails run-app
You’ll see that terminal will print out the webserver address, http://localhost:9090/mywebsite/ My grails server has been configured to run on port 9090. This has been done within my sdk/grails-1.3.7/scripts/_GrailsSettings.groovy file, but you can do it at run time as well.
>grails –Dserver.port=9090 run-app
Create Domain Class
>grails create-domain-class SiteUser
Create Controller
>grails create-controller SiteUser