我试图从一个依赖关系jar文件中提取一些.exe文件,并将它们放在$ {project.build.directory}/classes /下。maven-dependency-plugin:解压错误
但是,当我执行:
MVN清洁编译依赖性:解压
我得到:
未能执行目标org.apache.maven.plugins:Maven的依赖关系的插件:2.10:在项目上解压缩(default-cli)简单:需要伪像或伪像项目 - > [帮助1
我已验证依赖关系可用在我的本地存储库中。
在我的pom例子中,我用junit作为例子,但无论我列出哪个依赖项,我都会得到同样的错误。
的pom.xml:
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.10</version>
<executions>
<execution>
<id>unpack</id>
<phase>package</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.10</version>
<type>jar</type>
<overWrite>false</overWrite>
<outputDirectory>${project.build.directory}/classes/externaltools</outputDirectory>
<includes>**/*.txt</includes>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
</build>
我知道它说的是.txt lin pom,而我在这个问题中讨论了.exe文件。 – PistolPete