Packaging d'applications multi-module
Bonjour,
je suis à la recherche d'un plugins maven permettant de faire le paclaging d'une application. Exemple quand je tape la commande, j'obtient un zip ayant cette arbo:
- bin (les .bat que j'ai écrit permettant de lancer l'application)
- libs/externe/*.jar
- libs/moduleProjet/*.jar
...
pour le moment je test assembly et j'ai le fichier de configuration suivant:
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
| <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>monprojet</id>
<formats>
<format>zip</format>
</formats>
<!-- CREATION DU REPERTOIRE CONFIG CONTENANT LES FICHIERS DE CONFIGURATION -->
<fileSets>
<fileSet>
<directory>src/main/resources</directory>
<outputDirectory>config/</outputDirectory>
</fileSet>
</fileSets>
<dependencySets>
<!-- CREATION DU REPERTOIRE DISTRIB QUI CONTIENT LES JARS DU PROJET -->
<dependencySet>
<outputDirectory>/distrib/</outputDirectory>
<includes>
<include>monprojet*:*</include>
</includes>
</dependencySet>
<!-- CREATION DU REPERTOIRE LIBS QUI CONTIENT L'ENSEMBLE DES LIBS EXTERNES -->
<dependencySet>
<outputDirectory>/libs</outputDirectory>
<outputFileNameMapping>${artifact.artifactId}-${artifact.groupId}.${artifact.extension}
</outputFileNameMapping>
<unpack>false</unpack>
<scope>runtime</scope>
<excludes>
<exclude>monprojet*:*</exclude>
</excludes>
</dependencySet>
</dependencySets>
</assembly> |
Je pense qu'il y a mieux ! Comment faire pour compiler, l'ensemble des modules de mon projet à la volé (afin d'en faire un .jar pour le mettre dans distrib) tout en excluant les fichiers se trouvant dans resources...
Merci.