我遇到了maven-ear-plugin的问题,该问题由于“未定义依赖项”而一直失败,这是我的POM
<groupId>org.jolie</groupId>
<artifactId>ear-test1</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>ear</packaging>
<name>ear-test1</name>
<url>http://maven.apache.org</url>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.0.2</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ear-plugin</artifactId>
<version>2.6</version>
<configuration>
<version>5</version>
<defaultLibBundleDir>lib</defaultLibBundleDir>
<modules>
<ejbModule>
<groupId>org.jolie</groupId>
<artifactId>Test1</artifactId>
</ejbModule>
<jarModule>
<groupId>org.jolie-lang</groupId>
<artifactId>jolie</artifactId>
</jarModule>
</modules>
</configuration>
</plugin>
</plugins>
</build>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.jolie</groupId>
<artifactId>Test1</artifactId>
<version>0.0.1-SNAPSHOT</version>
<type>ejb</type>
</dependency>
<dependency>
<groupId>org.jolie-lang</groupId>
<artifactId>jolie</artifactId>
<version>1.9.0-git</version>
<type>jar</type>
</dependency>
</dependencies>
</dependencyManagement>
` 我尝试了每种可能的组合,但是eclipse似乎没有更改pom文件上的错误状态而不指定了什么错误
谢谢
答案 0 :(得分:0)
好吧,我想我应该考虑一下新pom的顺序
<modelVersion>4.0.0</modelVersion>
<groupId>org.jolie</groupId>
<artifactId>ear-test1</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>ear</packaging>
<name>ear-test1</name>
<url>http://maven.apache.org</url>
<dependencies>
<dependency>
<groupId>org.jolie</groupId>
<artifactId>Test1</artifactId>
<version>0.0.1-SNAPSHOT</version>
<type>ejb</type>
</dependency>
<dependency>
<groupId>org.jolie-lang</groupId>
<artifactId>jolie</artifactId>
<version>1.9.0-git</version>
<type>jar</type>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.0.2</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ear-plugin</artifactId>
<version>2.6</version>
<configuration>
<version>5</version>
<defaultLibBundleDir>lib</defaultLibBundleDir>
<modules>
<ejbModule>
<groupId>org.jolie</groupId>
<artifactId>Test1</artifactId>
</ejbModule>
<jarModule>
<groupId>org.jolie-lang</groupId>
<artifactId>jolie</artifactId>
</jarModule>
</modules>
</configuration>
</plugin>
</plugins>
</build>
</project>