0

我有一个带有 1 个父级和 5 个模块的 Maven 项目。其中一个模块(称为P)是打包“maven-plugin”的,它被配置为在其他模块(称为T)的执行阶段“process-test-classes”中运行。

模块 T 有 pom.xml 如下。我省略了依赖项,但它们不包括 P。在许多其他情况下,它都可以在命令行中完美运行。

问题:无论我做什么 Eclipse 都会显示“找不到工件 org.local.enhancer:pom:0.0.2-SNAPSHOT pom.xml /test line 1 Maven Configuration Problem ”。

似乎问题是在安装“m2e-wtp”v0.17 以解决其他有问题的 jar 问题后开始的。配置为 Eclipse Juno SR2、m2e v1.3.1、m2e-wtp v0.17。

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
          <modelVersion>4.0.0</modelVersion>
          <parent>
            <artifactId>parent</artifactId>
            <groupId>org.local</groupId>
            <version>0.0.2</version>
            <relativePath>..</relativePath>
          </parent>
          <artifactId>test</artifactId>
            <dependencies>
                 ...
            </dependencies>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.local</groupId>
                        <artifactId>enhancer</artifactId>
                        <version>0.0.2-SNAPSHOT</version> 
                        <executions>
                            <execution>
                                <phase>process-test-classes</phase>
                                <goals>
                                    <goal>enhance</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>    
        </project>

有人对此有任何见解吗?谢谢!

4

0 回答 0