我试图从我公司的Nexus仓库中将战争文件复制到特定位置。我使用Maven的依赖,插件以下列方式:从Maven仓库复制工件的最新版本
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.1</version>
<executions>
<execution>
<id>copy-to-output</id>
<phase>prepare-package</phase>
<goals>
<goal>copy</goal>
</goals>
</execution>
</executions>
<configuration>
<artifactItems>
<artifactItem>
<groupId>com.mycompany</groupId>
<artifactId>myproduct</artifactId>
<version>2.3.0</version>
<type>war</type>
<overWrite>false</overWrite>
</artifactItem>
</artifactItems>
<outputDirectory>${basedir}/src/main/output</outputDirectory>
</configuration>
</plugin>
的问题出现时,我试图用<version>RELEASE</version>
,而不是某个特定版本(或者没有版本的话),以获得最新版本(尽管不是最佳实践,在这种情况下它是安全的) - 它不起作用。有什么想法吗?
它是否适用于版本范围? – falstro 2010-07-26 14:24:25
不,我试过[2.3.0,)没有运气 – rperez 2010-07-26 14:26:52