I have a project with two modules: client and server. In the parent pom.xml I added info for the deployment phase, so as to deploy to a local directory:
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>org.my</groupId>
<artifactId>myTest</artifactId>
<version>0.1</version>
<packaging>pom</packaging>
<name>myTest</name>
<modules>
<module>server</module>
<module>client</module>
</modules>
<!-- for: mvn deploy -->
<distributionManagement>
<repository>
<id> myRepo </id>
<url> file:myDeployDir </url>
</repository>
</distributionManagement>
</project>
When I run mvn deploy
not only server-0.1.jar and client-0.1.jar get copied to myDeploy
but a sum of 33 (!) files: *pom *sha1 *md5 *xml for pom, metadata and jar.
How can I set that only server-0.1.jar and client-0.1.jar should be copied?
Thanks!
Use maven deploy-file
deploy:deploy-file is used to install a single artifact along with its pom. In that case the artifact information can be taken from an optionally specified pomFile, but can be completed/overriden using the command line.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With