Grails 3.0.1 add in Eclipse show error Specified d

2020-07-03 07:00发布

问题:

When I try to install/import Grails 3.0.1 in Eclipse I get error message "Specified directory does not appear to be a Grails installation".

I already have installed Groovy Compiler 2.4.3. but still get same error message.

How I can install Grails 3.0.1 in Eclipse 4.4?

回答1:

At grails folder you can put a file "build.properties",

/grails-3.0.1/build.properties
             /install
             /license
             /.......

the content of this file is a single line "grails.version=3.0.1", without quotes. :-)

Now eclipse will recognize it as Grails installation.

Regards



回答2:

Grails 3 is very different from earlier versions of Grails, in particular being based on Spring Boot. It will be a while before the IDEs have support for Grails 3. Eclipse will probably not have support for Grails 3 as 3.6.4 has been announced as the last release of GGTS and the Grails and Groovy tooling now that Pivotal has abandoned Grails and Groovy.



回答3:

I use the lattest ggts from sping (3.6.4) the gradle plugin (installed over the spring dashboard) and the latest snapshot release of the groovy plugin for eclipse to get a groovy 2.4 compiler.

With this setup import your grails3 application as gradle application works for me.



回答4:

Here are the steps for working with Grails 3 in Eclipse. 1) Get latest grails 3.X version and setup in the system. 2) Now create grails app using command line. 3) Install Gradle plugin in eclipse if not already there. 4) Import project as Gradle in eclipse, Gradle will download all required dependencies.