Use dependency plugin to copy runtime lib to MOD-INF dirs

This commit is contained in:
Antonin Delpeuch 2018-09-11 10:55:29 +01:00
parent f2c0361bfc
commit c12502aaae
24 changed files with 123 additions and 51 deletions

View File

@ -81,8 +81,20 @@
<artifactId>maven-dependency-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<skip>true</skip>
<outputFile>target/classpath.txt</outputFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>module/MOD-INF/lib</outputDirectory>
<includeScope>runtime</includeScope>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
@ -93,6 +105,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>main</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>

View File

@ -79,8 +79,20 @@
<artifactId>maven-dependency-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<skip>true</skip>
<outputFile>target/classpath.txt</outputFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>module/MOD-INF/lib</outputDirectory>
<includeScope>runtime</includeScope>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
@ -91,6 +103,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>main</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>

View File

@ -78,14 +78,22 @@
<artifactId>maven-dependency-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<skip>true</skip>
<outputFile>target/classpath.txt</outputFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>module/MOD-INF/lib</outputDirectory>
<includeScope>runtime</includeScope>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
</plugins>
</pluginManagement>
</build>
<dependencies>
@ -93,6 +101,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>main</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>

View File

@ -71,19 +71,27 @@
<skip>true</skip>
</configuration>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<skip>true</skip>
<outputFile>target/classpath.txt</outputFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>module/MOD-INF/lib</outputDirectory>
<includeScope>runtime</includeScope>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
</build>
<dependencies>
@ -91,6 +99,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>main</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>

View File

@ -62,19 +62,27 @@
<encoding>UTF-8</encoding>
</configuration>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<skip>true</skip>
<outputFile>target/classpath.txt</outputFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>module/MOD-INF/lib</outputDirectory>
<includeScope>runtime</includeScope>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
</build>
<dependencies>
@ -82,6 +90,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>main</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>

View File

@ -78,16 +78,25 @@
</suiteXmlFiles>
</configuration>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<skip>true</skip>
<outputFile>target/classpath.txt</outputFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>module/MOD-INF/lib</outputDirectory>
<includeScope>runtime</includeScope>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
@ -98,7 +107,7 @@
<id>install-wdtk-datamodel</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/module/MOD-INF/lib/wdtk-datamodel-0.9.0-SNAPSHOT-jar-with-dependencies.jar</file>
<file>${basedir}/lib/wdtk-datamodel-0.9.0-SNAPSHOT-jar-with-dependencies.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>org.wikidata.wdtk</groupId>
<artifactId>wdtk-datamodel</artifactId>
@ -114,7 +123,7 @@
<id>install-wdtk-wikibaseapi</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/module/MOD-INF/lib/wdtk-wikibaseapi-0.9.0-SNAPSHOT.jar</file>
<file>${basedir}/lib/wdtk-wikibaseapi-0.9.0-SNAPSHOT.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>org.wikidata.wdtk</groupId>
<artifactId>wdtk-wikibaseapi</artifactId>
@ -128,9 +137,7 @@
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
</build>
<dependencies>
@ -138,6 +145,7 @@
<groupId>${project.groupId}</groupId>
<artifactId>main</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>

View File

@ -94,8 +94,19 @@
<artifactId>maven-dependency-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<skip>true</skip>
<outputFile>target/classpath.txt</outputFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>webapp/WEB-INF/lib</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
@ -118,7 +129,7 @@
<id>install-marc4j</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/webapp/WEB-INF/lib/marc4j-2.4.jar</file>
<file>${basedir}/lib/marc4j-2.4.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>marc4j</groupId>
<artifactId>marc4j</artifactId>
@ -134,7 +145,7 @@
<id>install-tableschema</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/webapp/WEB-INF/lib/tableschema-java-1.0-SNAPSHOT.jar</file>
<file>${basedir}/lib/tableschema-java-1.0-SNAPSHOT.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>io.frictionlessdata</groupId>
<artifactId>tableschema-java</artifactId>
@ -150,7 +161,7 @@
<id>install-datapackage</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/webapp/WEB-INF/lib/datapackage-java-1.0-SNAPSHOT.jar</file>
<file>${basedir}/lib/datapackage-java-1.0-SNAPSHOT.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>io.frictionlessdata</groupId>
<artifactId>datapackage-java</artifactId>
@ -166,7 +177,7 @@
<id>install-opencsv</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/webapp/WEB-INF/lib/opencsv-2.4-SNAPSHOT.jar</file>
<file>${basedir}/lib/opencsv-2.4-SNAPSHOT.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>net.sf.opencsv</groupId>
<artifactId>opencsv</artifactId>
@ -182,7 +193,7 @@
<id>install-butterfly</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/webapp/WEB-INF/lib/butterfly-1.0.1.jar</file>
<file>${basedir}/lib/butterfly-1.0.1.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>edu.mit.simile</groupId>
<artifactId>butterfly</artifactId>
@ -198,7 +209,7 @@
<id>install-vicino</id>
<phase>process-resources</phase>
<configuration>
<file>${basedir}/webapp/WEB-INF/lib/vicino-1.1.jar</file>
<file>${basedir}/lib/vicino-1.1.jar</file>
<repositoryLayout>default</repositoryLayout>
<groupId>edu.mit.simile</groupId>
<artifactId>vicino</artifactId>