I'm trying to package a text based file into .tar using maven. To achieve this I used an assembly plugin and it worked, but along with the file tar a jar is also being generated. How can I avoid that?
<assembly
xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>all</id>
<formats>
<format>tar</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<fileSets>
<fileSet>
<directory>configuration</directory>
<fileMode>0444</fileMode>
</fileSet>
</fileSets>
</assembly>
You can change the packaging of your project. I guess current packaging is
jar
, and thus the creation of a jar. You may usepom
and configure the assembly plugin to attach its result (the tar) to your build.You could also configure the jar plugin, to skip the creation of empty jar (if it is your case).