2011-01-28 2 views

답변

0

이러한 옵션이없는 경우 bugreport을 만들어 이러한 매개 변수를 소개 할 수 있습니다.

해결 방법으로, 프로젝트에서 grails 명령을 래핑 한 build.xml을 작성하고이 래퍼를 사용하여 프로젝트를 빌드 할 수 있습니다. Griffon은 초기 버전에서 이와 같은 래퍼 build.xml을 자동으로 생성했습니다. 모양은 다음과 같습니다.

<project name="Foo" default="test"> 

    <!-- ================================= 
      target: clean 
     ================================= --> 
    <target name="clean" description="--> Cleans a Grails application"> 
     <grails> 
      <arg value="clean"/> 
     </grails> 
    </target> 

    <!-- ... --> 

    <!-- set up the grails macro --> 
    <property environment="env"/> 
    <property name="grails.home" value="${env.GRAILS_HOME}"/> 
    <property name="jdk.home" value="${env.JAVA_HOME}"/> 
    <condition property="grails" value="griffon.bat"> 
     <os family="windows"/> 
    </condition> 
    <property name="grails" value="grails" /> 
    <macrodef name="grails"> 
     <element name="grails-args" implicit="yes"/> 
     <sequential> 
      <exec executable="${grails.home}/bin/${grails}" failonerror="true"> 
       <env key="JAVA_HOME" value="${jdk.home}"/> 
       <env key="GRAILS_HOME" value="${grails.home}"/> 
       <grails-args/> 
      </exec> 
     </sequential> 
    </macrodef> 
    <!-- end set up the grails macro --> 

</project> 
관련 문제