2.1 安装的前提条件 - Reference Documentation
Authors: Graeme Rocher, Peter Ledbrook, Marc Palmer, Jeff Brown, Luke Daley, Burt Beckwith
Version: null
2.1 安装的前提条件
Before installing Grails you will as a minimum need a Java Development Kit (JDK) installed version 1.6 or above and environment variable called Note that although JDK 1.6 is required to use Grails at development time it is possible to deploy Grails to JDK 1.5 VMs by setting the In addition, Grails supports Servlet versions 2.5 and above. If you wish to use newer features of the Servlet API (such as 3.0) you should configure the
在安装Grails以前,你至少需要先安装1.6或者更高版本的JDK,并且设置名为JAVA_HOME pointing to the location of this installation. On some platforms (for example OS X) the Java installation is automatically detected. However in many cases you will want to manually configure the location of Java. For example:export JAVA_HOME=/Library/Java/Home
export PATH="$PATH:$JAVA_HOME/bin"grails.project.source.level and grails.project.target.level settings to "1.5" in grails-app/conf/BuildConfig.groovy:grails.project.source.level = 1.5 grails.project.target.level = 1.5
grails.servlet.version in BuildConfig.groovy appropriately:grails.servlet.version = "3.0"JAVA_HOME全局环境变量来指向它。有些平台(比如OS X),Java的安装是自动检测的,但是还是有不少的平台是需要手工来配置Java的安装位置的,比如:export JAVA_HOME=/Library/Java/Home
export PATH="$PATH:$JAVA_HOME/bin"grails-app/conf/BuildConfig.groovy中的grails.project.source.level和grails.project.target.level值为"1.5":grails.project.source.level = 1.5 grails.project.target.level = 1.5
BuildConfig.groovy中的grails.servlet.version为合适的值才行,比如:grails.servlet.version = "3.0"
