Java Grails在IOException can';找不到文件';圣杯&x27;在构建插件时

Java Grails在IOException can';找不到文件';圣杯&x27;在构建插件时,java,windows,grails,path,javac,Java,Windows,Grails,Path,Javac,我正试图从命令行在Windows7(x64)上运行grails应用程序和插件。我可以在没有插件的情况下运行应用程序,但是当我将插件添加到项目中时,我会得到一个java.io.IOException,消息是无法运行程序“grails”(在目录“[plugin directory]”中):CreateProcess error=2,系统找不到指定的文件。grails/bin文件夹位于我的系统环境path变量中,在plugin目录的命令行中正常运行。这就好像java环境有自己的path变量,不包括gr

我正试图从命令行在Windows7(x64)上运行grails应用程序和插件。我可以在没有插件的情况下运行应用程序,但是当我将插件添加到项目中时,我会得到一个java.io.IOException,消息是
无法运行程序“grails”(在目录“[plugin directory]”中):CreateProcess error=2,系统找不到指定的文件
。grails/bin文件夹位于我的系统环境path变量中,在plugin目录的命令行中正常运行。这就好像java环境有自己的path变量,不包括grails。有什么想法吗

我已经在下面包含了应用程序的完整输出,并编辑了插件项目的路径。我希望今天下午向一位客户演示这个项目,非常感谢您的快速帮助

| Loading Grails 2.2.1
| Compiling 3 source files.....
| Compiling 3 source files.....
| Error Error executing script RunApp: : Execute failed: java.io.IOException: Cannot run program "grails" (in directory "[plugin directory]"): CreateProcess error=2, The system cannot find the file specified (NOTE: Stack trace has been filtered. Use --verbose to see entire trace.)
: Execute failed: java.io.IOException: Cannot run program "grails" (in directory "[plugin directory]"): CreateProcess error=2, The syst
em cannot find the file specified
        at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:675)
        at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:498)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
        at org.codehaus.gant.GantBuilder.invokeMethod(GantBuilder.java:99)
        at _Events$_run_closure2.doCall(_Events.groovy:35)
        at _Events$_run_closure2.doCall(_Events.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at _Events$_run_closure3.doCall(_Events.groovy:54)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.apache.tools.ant.BuildListener$targetStarted.call(Unknown Source)
        at org.codehaus.gant.GantBinding$_withTargetEvent_closure1.doCall(GantBinding.groovy:89)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:89)
        at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
        at RunApp$_run_closure1.doCall(RunApp.groovy:35)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
        at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:185)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
        at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at gant.Gant$_dispatch_closure5.doCall(Gant.groovy:381)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at gant.Gant$_dispatch_closure7.doCall(Gant.groovy:415)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at gant.Gant$_dispatch_closure7.doCall(Gant.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at gant.Gant.withBuildListeners(Gant.groovy:427)
        at gant.Gant.this$2$withBuildListeners(Gant.groovy)
        at gant.Gant$this$2$withBuildListeners.callCurrent(Unknown Source)
        at gant.Gant.dispatch(Gant.groovy:415)
        at gant.Gant.this$2$dispatch(Gant.groovy)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at gant.Gant.invokeMethod(Gant.groovy)
        at gant.Gant.executeTargets(Gant.groovy:591)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at gant.Gant.executeTargets(Gant.groovy:590)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
        at org.springsource.loaded.ri.ReflectiveInterceptor.jlrMethodInvoke(ReflectiveInterceptor.java:1243)
Caused by: java.io.IOException: Cannot run program "grails" (in directory "[plugin directory]"): CreateProcess error=2, The system cann
ot find the file specified
        at org.apache.tools.ant.taskdefs.Execute$Java13CommandLauncher.exec(Execute.java:862)
        at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:481)
        at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:495)
        at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:631)
        at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:672)
        ... 53 more
Caused by: java.io.IOException: CreateProcess error=2, The system cannot find the file specified
        ... 58 more
| Error Error executing script RunApp: : Execute failed: java.io.IOException: Cannot run program "grails" (in directory "[plugin directory]"): CreateProcess error=2, The system cannot find the file specified

BuildConfig.groovy
看起来怎么样?我已经注册了。客户端接口插件的位置与上面堆栈跟踪中编辑的[plugin directory]相同。您是否可以添加到您所谈论的导致问题的插件的问题中?你从项目目录运行app,对吗?这个插件是我自己写的。运行应用程序尝试从源代码构建插件时出错。