This is an automated email from the ASF dual-hosted git repository. jochen pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-fileupload.git
The following commit(s) were added to refs/heads/master by this push: new c3614f40 1.) Make projects importable into Eclipse by replacing resource sections in the pom with use of the dependency plugin. 2.) Add files, that are generated by Eclipse, to the Rat excludes. c3614f40 is described below commit c3614f40d7f99e055fcbb292b7b4ce401f2a7009 Author: Jochen Wiedmann <jochen.wiedm...@gmail.com> AuthorDate: Sun Jun 8 12:03:01 2025 +0200 1.) Make projects importable into Eclipse by replacing resource sections in the pom with use of the dependency plugin. 2.) Add files, that are generated by Eclipse, to the Rat excludes. --- commons-fileupload2-core/pom.xml | 82 ++++++++++++++++++---------- commons-fileupload2-jakarta-servlet5/pom.xml | 82 ++++++++++++++++++---------- commons-fileupload2-jakarta-servlet6/pom.xml | 82 ++++++++++++++++++---------- commons-fileupload2-javax/pom.xml | 82 ++++++++++++++++++---------- commons-fileupload2-portlet/pom.xml | 71 ++++++++++++++---------- 5 files changed, 254 insertions(+), 145 deletions(-) diff --git a/commons-fileupload2-core/pom.xml b/commons-fileupload2-core/pom.xml index d546dd51..5c6dd8a2 100644 --- a/commons-fileupload2-core/pom.xml +++ b/commons-fileupload2-core/pom.xml @@ -64,35 +64,59 @@ </dependencies> <build> - <resources> - <resource> - <directory>${basedir}/src/main/resources</directory> - </resource> - <!-- include NOTICE/LICENSE in generated jar --> - <resource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </resource> - </resources> - - <testResources> - <testResource> - <directory>src/test/resources</directory> - </testResource> - <!-- include NOTICE/LICENSE in generated test jar --> - <testResource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </testResource> - </testResources> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>dep-unpack-main-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.outputDirectory}</outputDirectory> + </configuration> + </execution> + <execution> + <id>dep-unpack-test-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.testOutputDirectory}</outputDirectory> + </configuration> + </execution> + </executions> + <configuration> + <artifactItems> + <artifactItem> + <groupId>org.apache</groupId> + <artifactId>apache-jar-resource-bundle</artifactId> + <version>1.4</version> + <fileMappers> + <org.codehaus.plexus.components.io.filemappers.FlattenFileMapper/> + </fileMappers> + </artifactItem> + </artifactItems> + <includes>META-INF/LICENSE.txt,META-INF/NOTICE.txt</includes> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.rat</groupId> + <artifactId>apache-rat-plugin</artifactId> + <configuration> + <excludes combine.children="append"> + <exclude>.project</exclude> + <exclude>.classpath</exclude> + <exclude>.settings/**/</exclude> + <exclude>bin/**</exclude> + </excludes> + </configuration> + </plugin> + </plugins> </build> </project> diff --git a/commons-fileupload2-jakarta-servlet5/pom.xml b/commons-fileupload2-jakarta-servlet5/pom.xml index 6c3f70e9..d1fca15d 100644 --- a/commons-fileupload2-jakarta-servlet5/pom.xml +++ b/commons-fileupload2-jakarta-servlet5/pom.xml @@ -86,35 +86,59 @@ </dependencies> <build> - <resources> - <resource> - <directory>${basedir}/src/main/resources</directory> - </resource> - <!-- include NOTICE/LICENSE in generated jar --> - <resource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </resource> - </resources> - - <testResources> - <testResource> - <directory>src/test/resources</directory> - </testResource> - <!-- include NOTICE/LICENSE in generated test jar --> - <testResource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </testResource> - </testResources> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>dep-unpack-main-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.outputDirectory}</outputDirectory> + </configuration> + </execution> + <execution> + <id>dep-unpack-test-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.testOutputDirectory}</outputDirectory> + </configuration> + </execution> + </executions> + <configuration> + <artifactItems> + <artifactItem> + <groupId>org.apache</groupId> + <artifactId>apache-jar-resource-bundle</artifactId> + <version>1.4</version> + <fileMappers> + <org.codehaus.plexus.components.io.filemappers.FlattenFileMapper/> + </fileMappers> + </artifactItem> + </artifactItems> + <includes>META-INF/LICENSE.txt,META-INF/NOTICE.txt</includes> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.rat</groupId> + <artifactId>apache-rat-plugin</artifactId> + <configuration> + <excludes combine.children="append"> + <exclude>.project</exclude> + <exclude>.classpath</exclude> + <exclude>.settings/**/</exclude> + <exclude>bin/**</exclude> + </excludes> + </configuration> + </plugin> + </plugins> </build> </project> diff --git a/commons-fileupload2-jakarta-servlet6/pom.xml b/commons-fileupload2-jakarta-servlet6/pom.xml index d80045ae..9e2492b1 100644 --- a/commons-fileupload2-jakarta-servlet6/pom.xml +++ b/commons-fileupload2-jakarta-servlet6/pom.xml @@ -86,35 +86,59 @@ </dependencies> <build> - <resources> - <resource> - <directory>${basedir}/src/main/resources</directory> - </resource> - <!-- include NOTICE/LICENSE in generated jar --> - <resource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </resource> - </resources> - - <testResources> - <testResource> - <directory>src/test/resources</directory> - </testResource> - <!-- include NOTICE/LICENSE in generated test jar --> - <testResource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </testResource> - </testResources> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>dep-unpack-main-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.outputDirectory}</outputDirectory> + </configuration> + </execution> + <execution> + <id>dep-unpack-test-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.testOutputDirectory}</outputDirectory> + </configuration> + </execution> + </executions> + <configuration> + <artifactItems> + <artifactItem> + <groupId>org.apache</groupId> + <artifactId>apache-jar-resource-bundle</artifactId> + <version>1.4</version> + <fileMappers> + <org.codehaus.plexus.components.io.filemappers.FlattenFileMapper/> + </fileMappers> + </artifactItem> + </artifactItems> + <includes>META-INF/LICENSE.txt,META-INF/NOTICE.txt</includes> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.rat</groupId> + <artifactId>apache-rat-plugin</artifactId> + <configuration> + <excludes combine.children="append"> + <exclude>.project</exclude> + <exclude>.classpath</exclude> + <exclude>.settings/**/</exclude> + <exclude>bin/**</exclude> + </excludes> + </configuration> + </plugin> + </plugins> </build> </project> diff --git a/commons-fileupload2-javax/pom.xml b/commons-fileupload2-javax/pom.xml index 55e38c83..c2e15b4f 100644 --- a/commons-fileupload2-javax/pom.xml +++ b/commons-fileupload2-javax/pom.xml @@ -80,35 +80,59 @@ </dependencies> <build> - <resources> - <resource> - <directory>${basedir}/src/main/resources</directory> - </resource> - <!-- include NOTICE/LICENSE in generated jar --> - <resource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </resource> - </resources> - - <testResources> - <testResource> - <directory>src/test/resources</directory> - </testResource> - <!-- include NOTICE/LICENSE in generated test jar --> - <testResource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </testResource> - </testResources> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>dep-unpack-main-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.outputDirectory}</outputDirectory> + </configuration> + </execution> + <execution> + <id>dep-unpack-test-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.testOutputDirectory}</outputDirectory> + </configuration> + </execution> + </executions> + <configuration> + <artifactItems> + <artifactItem> + <groupId>org.apache</groupId> + <artifactId>apache-jar-resource-bundle</artifactId> + <version>1.4</version> + <fileMappers> + <org.codehaus.plexus.components.io.filemappers.FlattenFileMapper/> + </fileMappers> + </artifactItem> + </artifactItems> + <includes>META-INF/LICENSE.txt,META-INF/NOTICE.txt</includes> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.rat</groupId> + <artifactId>apache-rat-plugin</artifactId> + <configuration> + <excludes combine.children="append"> + <exclude>.project</exclude> + <exclude>.classpath</exclude> + <exclude>.settings/**/</exclude> + <exclude>bin/**</exclude> + </excludes> + </configuration> + </plugin> + </plugins> </build> </project> diff --git a/commons-fileupload2-portlet/pom.xml b/commons-fileupload2-portlet/pom.xml index 967ee332..4259dcbd 100644 --- a/commons-fileupload2-portlet/pom.xml +++ b/commons-fileupload2-portlet/pom.xml @@ -49,6 +49,7 @@ <commons.jacoco.branchRatio>1.00</commons.jacoco.branchRatio> <commons.jacoco.lineRatio>0.64</commons.jacoco.lineRatio> <commons.jacoco.complexityRatio>0.60</commons.jacoco.complexityRatio> + <rat.skip>true</rat.skip> </properties> <dependencies> <dependency> @@ -95,35 +96,47 @@ </dependencies> <build> - <resources> - <resource> - <directory>${basedir}/src/main/resources</directory> - </resource> - <!-- include NOTICE/LICENSE in generated jar --> - <resource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </resource> - </resources> - - <testResources> - <testResource> - <directory>src/test/resources</directory> - </testResource> - <!-- include NOTICE/LICENSE in generated test jar --> - <testResource> - <directory>${commons.parent.dir}</directory> - <targetPath>META-INF</targetPath> - <includes> - <include>NOTICE.txt</include> - <include>LICENSE.txt</include> - </includes> - </testResource> - </testResources> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>dep-unpack-main-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.outputDirectory}</outputDirectory> + </configuration> + </execution> + <execution> + <id>dep-unpack-test-resources</id> + <goals> + <goal>unpack</goal> + </goals> + <phase>generate-resources</phase> + <configuration> + <outputDirectory>${project.build.testOutputDirectory}</outputDirectory> + </configuration> + </execution> + </executions> + <configuration> + <artifactItems> + <artifactItem> + <groupId>org.apache</groupId> + <artifactId>apache-jar-resource-bundle</artifactId> + <version>1.4</version> + <fileMappers> + <org.codehaus.plexus.components.io.filemappers.FlattenFileMapper/> + </fileMappers> + </artifactItem> + </artifactItems> + <includes>META-INF/LICENSE.txt,META-INF/NOTICE.txt</includes> + </configuration> + </plugin> + </plugins> </build> </project>