[b][size=x-large]问题[/size][/b]
eclipse导入maven工程报错:
[quote]
maven-dependency-plugin (goals "copy-dependencies", "unpack") is not supported by m2e.
[/quote]
[b][size=x-large]原因[/size][/b]
eclipse m2e插件并不支持所有的maven plugin,对于不支持的plugin就只能报错了,参见 [url=http://wiki.eclipse.org/M2E_plugin_execution_not_covered]M2E plugin execution not covered[/url]
[b][size=x-large]解决方案[/size][/b]
在报错的pom.xml文件中,<build>结点下插入以下结点
eclipse导入maven工程报错:
[quote]
maven-dependency-plugin (goals "copy-dependencies", "unpack") is not supported by m2e.
[/quote]
[b][size=x-large]原因[/size][/b]
eclipse m2e插件并不支持所有的maven plugin,对于不支持的plugin就只能报错了,参见 [url=http://wiki.eclipse.org/M2E_plugin_execution_not_covered]M2E plugin execution not covered[/url]
[b][size=x-large]解决方案[/size][/b]
在报错的pom.xml文件中,<build>结点下插入以下结点
<pluginManagement>
<plugins>
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<versionRange>[2.0,)</versionRange>
<goals>
<goal>copy-dependencies</goal>
</goals>
</pluginExecutionFilter>
<action>
<execute />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
本文详细介绍了Eclipse导入Maven工程时遇到的maven-dependency-plugin插件不支持的问题,并提供了通过在pom.xml文件中插入特定结点来解决此错误的方法。
1686

被折叠的 条评论
为什么被折叠?



