4

Need help with the following Eclipse m2e issue:

Plugin execution not covered by lifecycle configuration: com.google.appengine:appengine-maven-plugin:1.8.3:endpoints_get_discovery_doc (execution: default, phase: compile)

<plugin>
    <groupId>com.google.appengine</groupId>
    <artifactId>appengine-maven-plugin</artifactId>
    <version>1.8.3</version>
    <configuration>                                     
      <enableJarClasses>false</enableJarClasses>
    </configuration>
    <executions>
      **<execution>**
        <goals>
          <goal>endpoints_get_discovery_doc</goal>
        </goals>
      </execution>
    </executions>
</plugin>

Any ideas? The pom.xml looks like: https://github.com/GoogleCloudPlatform/appengine-endpoints-tictactoe-java-maven/blob/master/pom.xml

4

2 回答 2

2

把它放在<build>你的 pom 的部分

<pluginManagement>
    <plugins>
        <plugin>
            <groupId>org.eclipse.m2e</groupId>
            <artifactId>lifecycle-mapping</artifactId>
            <version>1.0.0</version>
            <configuration>
                <lifecycleMappingMetadata>
                    <pluginExecutions>
                        <pluginExecution>
                            <pluginExecutionFilter>
                                <groupId>com.google.appengine</groupId>
                                <artifactId>appengine-maven-plugin</artifactId>
                                <versionRange>[1.8.3,)</versionRange>
                                <goals>
                                    <goal>endpoints_get_discovery_doc</goal>
                                </goals>
                            </pluginExecutionFilter>
                            <action>
                                <ignore></ignore>
                            </action>
                        </pluginExecution>
                    </pluginExecutions>
                </lifecycleMappingMetadata>
            </configuration>
        </plugin>
    </plugins>
</pluginManagement>

资料来源:M2Eclipse 文档

于 2016-01-02T13:43:59.853 回答
1

如何解决 Spring Data Maven Builds 的“生命周期配置未涵盖的插件执行”已回答了这个问题

唯一的区别是,在您的情况下,您必须将 pluginExecutionFilter 标记替换为:

<pluginExecutionFilter>
    <groupId>com.google.appengine</groupId>
    <artifactId>appengine-maven-plugin</artifactId>
    <versionRange>1.8.3</versionRange>
    <goals>
        <goal>test-compile</goal>
        <goal>compile</goal>
    </goal>
</pluginExecutionFilter>
于 2013-09-05T14:47:32.657 回答