Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

The Definitive Guide To Grails Sample Code

branch: master
Octocat-spinner-32 Chapter01 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter02 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter03 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter04 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter05 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter06 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter07 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter08 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter09 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter11 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter12 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter13-album-art-plugin Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter13-blog-plugin Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter13-simple-cache-plugin Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter13 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter14 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter15 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter16 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 Chapter17 Added XML declaration tag to every ivy.xml and ivysettings.xml file
Octocat-spinner-32 graphics take two
Octocat-spinner-32 plugins released blog plugin into dgg sample plugin repo
Octocat-spinner-32 README.txt Merge branch 'master' of git@github.com:grails/grails
Octocat-spinner-32 gtunes-data.xml some sample data
Octocat-spinner-32 svn-commit.tmp take two
README.txt
The Definitive Guide To Grails - 2nd Edition
--------------------------------------------

This document describes how to get the sample code for "The Definitive Guide to Grails - 2nd Edition" (Apress). The sample application models an online music store called gTunes and is organized by chapter, with each directory related to a single chapter (eg. Chapter01). You will need to the following software installed before you can use the samples:

* Grails 1.1 - Available from http://grails.org/Download (installation instructions can be found the book)
* MySQL - Available from http://dev.mysql.com/

You will need to create databases (or catalogues in MySQL lingo) in MySQL for each chapter that follow the sequence gtunes_ch01, gtunes_ch02 etc. You also need to setup a user account that can access each database with the following details:

* username: gtunes
* password: password

With that done you can run each chapter using the following example steps from a terminal window:

$ cd Chapter01
$ grails upgrade
$ grails run-app

Importing Your iTunes Library
-----------------------------

In some of the chapters you can use your iTunes library as sample data for the application. To do so you can run the following command:

$ grails import-itunes-library ~/Music/iTunes/iTunes\ Music\ Library.xml

If you're on a Windows system the path will likely differ.

Importing Sample Data
---------------------

From Chapter 12 onwards there is also a Gant script that you can use to import some sample data:

$ grails import-library-from-xml ../gtunes-data.xml

Note: The paths to the physical files will probably not be correct for your machine, so playback of tracks that is implemented in Chapter 14 will not work unless you modify the paths. 


Something went wrong with that request. Please try again.