【发布时间】:2015-08-03 08:07:47
【问题描述】:
我尝试将与 eclipse luna 一起使用的 maven 多模块项目导入 eclipse mars。这个多模块 maven 项目在 eclipse mars 中没有源文件夹,依赖项也不存在:
我无法将 src/main/java 文件夹添加为源文件夹:
其他 Maven 多模块项目也可以工作。这个项目的不同之处在于它使用了groovy-eclipse-compiler:
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.3</version>
<dependencies>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-eclipse-compiler</artifactId>
<version>2.9.2-01</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-eclipse-batch</artifactId>
<version>2.4.3-01</version>
<scope>compile</scope>
</dependency>
</dependencies>
<configuration>
<compilerId>groovy-eclipse-compiler</compilerId>
<fork>true</fork>
<verbose>false</verbose>
<source>1.7</source>
<target>1.7</target>
<encoding>UTF-8</encoding>
<showDeprecation>true</showDeprecation>
<verbose />
</configuration>
</plugin>
为了在 Eclipse 中使用正确的 groovy 工具,我从更新站点安装了 groovy-eclipse:
Groovy Eclipse 2.9.2 snapshot builds for Eclipse 4.5 are available, update site http://dist.springsource.org/snapshot/GRECLIPSE/e4.5/
我该怎么做才能让 eclipse mars 正确识别这个 maven 项目?
【问题讨论】:
-
我就是这样做的,但是正确的项目类型是什么意思?这是一个maven项目,所以将它作为一个maven项目导入..
-
导入 'as maven project' 后,我应该可以选择 "configure->convert to groovy project" 。但此选项不可用!
-
我在 groovy-eclipse github 页面上为此打开了一个问题:github.com/groovy/groovy-eclipse/issues/130,但我猜这个项目已经被孤立了。
标签: eclipse m2eclipse m2e m2e-wtp groovy-eclipse