eclipse添加m2eclipse插件,导入maven项目时,报错:Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-antrun-plugin:1.7。
解决办法:
1,官方:http://wiki.eclipse.org/M2E_plugin_execution_not_covered
2,快速解决:pom.xml文件中的<plugins>标签的上部添加如下代码,即可解决:
<pluginManagement> <plugins> <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself. --> <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-antrun-plugin</artifactId> <versionRange>[1.7,)</versionRange> <goals> <goal>run</goal> </goals> </pluginExecutionFilter> <action> <ignore /> </action> </pluginExecution> </pluginExecutions> </lifecycleMappingMetadata> </configuration> </plugin> </plugins> </pluginManagement>
原创文章,作者:奋斗,如若转载,请注明出处:https://blog.ytso.com/196200.html