zoukankan      html  css  js  c++  java
  • MyEclipse导入Maven项目报错 Plugin execution not covered by lifecycle configuration:

    web项目使用到mybatis,需要使用mybatis的自动生成代码插件,配置build部分如下:  

     1  <build>
     2       <pluginManagement></pluginManagement>
     3     <plugins>
     4       <plugin>
     5         <artifactId>maven-war-plugin</artifactId>
     6       </plugin>
     7       <plugin>
     8         <artifactId>maven-compiler-plugin</artifactId>
     9         <configuration>
    10           <source>1.6</source>
    11           <target>1.6</target>
    12         </configuration>
    13       </plugin>
    14       <plugin>
    15         <groupId>org.mybatis.generator</groupId>
    16         <artifactId>mybatis-generator-maven-plugin</artifactId>
    17         <version>1.3.2</version>
    18         <executions>
    19           <execution>
    20             <id>mapper-generate</id>
    21             <phase>generate-resources</phase>
    22             <goals>
    23               <goal>generate</goal>
    24             </goals>
    25           </execution>
    26         </executions>
    27         <dependencies>
    28           <dependency>
    29             <groupId>org.mybatis.generator</groupId>
    30             <artifactId>mybatis-generator-core</artifactId>
    31             <version>1.3.2</version>
    32           </dependency>
    33         </dependencies>
    34         <configuration>
    35           <verbose>true</verbose>
    36           <overwrite>true</overwrite>
    37           <configurationFile>srcmain
    esourcesgeneratorConfig.xml</configurationFile>
    38         </configuration>
    39       </plugin>
    40     </plugins>
    41   </build>

    execution标签处报错详细如下:

      

      

      报错内容:

    Plugin execution not covered by lifecycle configuration: org.mybatis.generator:mybatis-generator-maven-
    plugin:1.3.2:generate (execution: mapper-generate, phase: generate-resources)

    解决方法:

       <plugins> 标签外再套一个 <pluginManagement> 标签 解决

  • 相关阅读:
    PATA 1071 Speech Patterns.
    PATA 1027 Colors In Mars
    PATB 1038. 统计同成绩学生(20)
    1036. 跟奥巴马一起编程(15)
    PATA 1036. Boys vs Girls (25)
    PATA 1006. Sign In and Sign Out (25)
    读取web工程目录之外的图片并显示
    DOS命令
    java连接oracle集群
    servlet
  • 原文地址:https://www.cnblogs.com/iGel/p/4694343.html
Copyright © 2011-2022 走看看