“Plugin execution not covered by lifecycle configuration: xxx"问题的解决

问题提出:
在使用Maven过程中,碰到了如下问题:

Plugin execution not covered by lifecycle configuration: io.spring.javaformat:spring-javaformat-maven-plugin:0.0.4:validate
 (execution: default, phase: validate)  

错误信息截图如下:
“Plugin execution not covered by lifecycle configuration: xxx
项目中使用的pom.xml的片段如下:

<build>
   <plugins>
      ......
      <plugin>
                <groupId>io.spring.javaformatgroupId>
                <artifactId>spring-javaformat-maven-pluginartifactId>
                <version>${spring-javaformat.version}version>
                <executions>
                    <execution>
                        <phase>validatephase>
                        <inherited>trueinherited>
                        <configuration>
                            <skip>${disable.checks}skip>
                        configuration>
                        <goals>
                            <goal>validategoal>
                        goals>
                    execution>
                executions>
            plugin>
        plugins>
   .....
  build>

问题的解决:
经过一番网络上的查找之后,问题的定位为缺失造成的。 可以按照如下来修改:

 
    
        
             ... 
             ... 
                  ....
        
    

然后重新clean项目,编译之后,问题随即消失。

Reference
1. https://stackoverflow.com/questions/6352208/how-to-solve-plugin-execution-not-covered-by-lifecycle-configuration-for-sprin

你可能感兴趣的:(问题分析,Java技术)