码迷,mamicode.com
首页 > Web开发 > 详细

Plugin execution not covered by lifecycle configuration: aspectj-maven-plugin:1.8

时间:2016-10-08 01:30:49      阅读:277      评论:0      收藏:0      [点我收藏+]

标签:

现象:

eclipse导入existing maven project,(父项目包含很多子项目),子项目的pom.xml报错:

Plugin execution not covered by lifecycle configuration: org.codehaus.mojo:aspectj-maven-plugin:1.8:compile

(execution: default,phase:compile)

解决方法一:

enclose all the plugin tags inside a <pluginManagement> tag, like this:

<build>
    <pluginManagement>
        <plugins>
            <plugin> ... </plugin>
            <plugin> ... </plugin>
                  ....
        </plugins>
    </pluginManagement>
</build>
尝试该方法后:在pom.xml文件中前部分的<parent>标签处报同样的错误,无法解决。
解决方法二:

  Quickest way to solve this is:

  1. use quick-fix on the error in pom.xml and select Permanently mark goal run in pom.xml as ignored in Eclipse build - this will generate the required boilerplate code for you.

  2. After that just replace the <ignore/> or <ignore></ignore>tag with <execute/> tag in the generated configuration and you‘re done:

 

  <action>
      <execute/>
  </action>

尝试该方法后,红叉消失。
解决方法三:
配置eclipse
 Window-Perferences-Maven-Lifecycle Mapping
保存如下内容:
<?xml version="1.0" encoding="UTF-8"?>
<lifecycleMappingMetadata>
    <pluginExecutions>
    
        <pluginExecution>
            <pluginExecutionFilter>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>aspectj-maven-plugin</artifactId>
                <goals>
                    <goal>compile</goal>
                </goals>
                <versionRange>[1.3,)</versionRange>
            </pluginExecutionFilter>
            <action>
                <ignore />
            </action>
        </pluginExecution>
        
    </pluginExecutions>
</lifecycleMappingMetadata>
记得点击 ”Reload workspace lifecycle mappings metadata“按钮.
 
refer to :
http://stackoverflow.com/questions/6352208/how-to-solve-plugin-execution-not-covered-by-lifecycle-configuration-for-sprin
http://blog.csdn.net/xxd851116/article/details/25197373
 

 

Plugin execution not covered by lifecycle configuration: aspectj-maven-plugin:1.8

标签:

原文地址:http://www.cnblogs.com/linprogram/p/5936993.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!