maven-assembly-plugin

The maven assembly plugin moduleset sources instructions are not including any files and not matching the included modules

[亡魂溺海] 提交于 2019-12-06 17:49:45
问题 I have a multi-module maven project, and I'm trying to get the moduleset sources portion of the assembly plugin to work. I have modules " module_parent ", " module_a ", and " module_assembly ". module_a and module_assembly are children of module_parent . module_assembly has a declared pom dependency on module_a . module_assmebly has the assembly plugin, with the assembly.xml looking like: <?xml version="1.0"?> <assembly> <id>bin</id> <formats> <format>zip</format> </formats>

maven assembly plugin is not working with pluginManagement

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-06 15:22:56
Below is my configuration of maven-assembly-plugin and it's working fine.but when i am adding my all plugins inside the pluginManagement parent tag it's not working. I am not sure why it's not working <plugin> <artifactId>maven-assembly-plugin</artifactId> <version>2.2</version> <executions> <execution> <id>MyId</id> <phase>package</phase> <goals> <goal>single</goal> </goals> <configuration> <descriptor>assemblyFile.xml</descriptor> <appendAssemblyId>false</appendAssemblyId> </configuration> </execution> </executions> </plugin> The execution section of your maven-assembly-plugin should not be

Maven module for static files

心已入冬 提交于 2019-12-06 13:01:25
问题 I have a web application with spring and maven. The application is divided into maven modules. I have an "application-web" module that generates war. Another "application-ear" module that generates an ear. And another "application-static" with css, js and images that generates a zip file. This would be the outline of my application: application application-web (java code) application-ear application-static (css, js and images) application-resources (language properties) I want to deploy the

How to publish multiple jar files to maven on a clean install

五迷三道 提交于 2019-12-06 07:43:19
问题 I have a used the maven assembly plugin to create multiple jar from one jar now the problem is that I have to publish these jar to the local repo, just like other maven jars publish by them self when they are built maven clean install how will I be able to do this here is my pom file <project> <parent> <groupId>parent.common.bundles</groupId> <version>1.0</version> <artifactId>child-bundle</artifactId> </parent> <modelVersion>4.0.0</modelVersion> <groupId>common.dataobject</groupId>

Maven assembly on multi module project with special structure

久未见 提交于 2019-12-06 05:03:07
问题 I'm new to Maven, and I think I've started to get the idea of how it works. But I'm not able to understand the maven assembly plugin. What I want to achieve is this: When all projects has been packaged, with their respective dependencies, I want to have them all in the target directory. I don't want them to be packaged into one super-jar because the system is based on modules. Let me explain, I have a main project, the server, in the maven project "common", and I have two modules, "core" and

maven assembly create jar with dependency and class path

大城市里の小女人 提交于 2019-12-05 20:22:54
I have a maven project with a lot of dependencies. I want to pack all in a jar with dependency using assembly plugin, but I don't won't all the dependencies jars unpacked in a big mess. I want all of them do go into lib folder, but I don't know how to add the class path. my pom: <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>test.com</groupId> <artifactId>simple-weather</artifactId> <version>1.0

How to exclude some of the folders while creating zip file through maven

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-05 17:34:33
问题 <assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembl/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd"> <id>bin</id> <baseDirectory>/</baseDirectory> <formats> <format>zip</format> </formats> <fileSets> <fileSet> <directory>src/main</directory> <outputDirectory>/</outputDirectory> <excludes> <exclude>src/main/dml</exclude

How to make Maven assembly plugin dependencySets descriptor to include dependencies as defined in POM file?

◇◆丶佛笑我妖孽 提交于 2019-12-05 15:10:58
For example, a POM dependency declaration (this is just for demo purpose and not my actual code): <dependency> <groupId>ch.qos.logback</groupId> <artifactId>logback-classic</artifactId> <version>1.1.2</version> <exclusions> <exclusion> <groupId>*</groupId> <artifactId>*</artifactId> </exclusion> </exclusions> </dependency> <dependency>..</dependency> <dependency>..</dependency> My assembly dependencySets descriptor: <dependencySets> <dependencySet> <outputDirectory>lib</outputDirectory> <includes> <include>*:jar</include> </includes> <scope>runtime</scope> <useProjectArtifact>false<

how to add arbitrary information in manifest from maven assembly plugin

こ雲淡風輕ζ 提交于 2019-12-05 12:11:11
问题 i use the assembly plugin to create a uber jar from several maven artifacts. Now I like to add some company specific entries into the Manifest of the created assembly jar. But how ? the archive element doesnt allow arbitrary elements (or is there a way to add foobar: tutu inside the archive tag ?) also in addition with maven-jar-plugin it does not work as this only affects the default artifact of the project and not the assembled. Any idea how to do this ? 回答1: argh... after posting it i

How to include package.jar with maven-assembly-plugin

蹲街弑〆低调 提交于 2019-12-05 11:33:07
I used maven and maven-jar-plugin and maven-assembly-plugin to build a zip of my project including the projects jar and its dependencies. This is the plugin configuration: <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> <version>2.5</version> <configuration> <archive> <manifest> <mainClass>MyMainClass</mainClass> <addClasspath>true</addClasspath> <classpathPrefix>lib/</classpathPrefix> </manifest> </archive> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-assembly-plugin</artifactId> <version>2.4<