You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by cs...@apache.org on 2022/07/20 12:04:27 UTC

[maven-assembly-plugin] branch master updated: [MASSEMBLY-969] Update common artifact filters to 3.3.1 (#83)

This is an automated email from the ASF dual-hosted git repository.

cstamas pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-assembly-plugin.git


The following commit(s) were added to refs/heads/master by this push:
     new db292ea9 [MASSEMBLY-969] Update common artifact filters to 3.3.1 (#83)
db292ea9 is described below

commit db292ea981ab6d02e1123363d2c013d1a02f5481
Author: Tamas Cservenak <ta...@cservenak.net>
AuthorDate: Wed Jul 20 14:04:23 2022 +0200

    [MASSEMBLY-969] Update common artifact filters to 3.3.1 (#83)
    
    As version 3.3.0 has an unwanted change regarding 4 elements
    pattern and are parsed as GATV only, while before they were
    parsed as GATC as well.
    
    Created IT based on issue supplied POM and assembly descriptor.
---
 pom.xml                                            |   2 +-
 .../projects/dependency-sets/massembly-969/pom.xml | 197 +++++++++++++++++++++
 .../massembly-969/src/main/assembly/bin.xml        |  53 ++++++
 .../dependency-sets/massembly-969/verify.groovy    |  47 +++++
 4 files changed, 298 insertions(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index f757d14b..e9ea05ae 100644
--- a/pom.xml
+++ b/pom.xml
@@ -141,7 +141,7 @@ under the License.
     <dependency>
       <groupId>org.apache.maven.shared</groupId>
       <artifactId>maven-common-artifact-filters</artifactId>
-      <version>3.3.0</version>
+      <version>3.3.1</version>
     </dependency>
     <dependency>
       <groupId>org.apache.maven.shared</groupId>
diff --git a/src/it/projects/dependency-sets/massembly-969/pom.xml b/src/it/projects/dependency-sets/massembly-969/pom.xml
new file mode 100644
index 00000000..03693138
--- /dev/null
+++ b/src/it/projects/dependency-sets/massembly-969/pom.xml
@@ -0,0 +1,197 @@
+<?xml version="1.0"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<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>
+    <parent>
+        <groupId>org.apache.maven.plugin.assembly.test</groupId>
+        <artifactId>it-project-parent</artifactId>
+        <version>1</version>
+    </parent>
+
+    <groupId>test</groupId>
+    <artifactId>massembly-969</artifactId>
+    <version>1</version>
+    <properties>
+        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+        <javafx.version>18.0.1</javafx.version>
+    </properties>
+    <dependencies>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-base</artifactId>
+            <version>${javafx.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-base</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>win</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-base</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>linux</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-base</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>mac</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-controls</artifactId>
+            <version>${javafx.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-controls</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>win</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-controls</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>linux</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-controls</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>mac</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-web</artifactId>
+            <version>${javafx.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-web</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>win</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-web</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>linux</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-web</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>mac</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-media</artifactId>
+            <version>${javafx.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-media</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>win</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-media</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>linux</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-media</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>mac</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-swing</artifactId>
+            <version>${javafx.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-swing</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>win</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-swing</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>linux</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-swing</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>mac</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-graphics</artifactId>
+            <version>${javafx.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-graphics</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>win</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-graphics</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>linux</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.openjfx</groupId>
+            <artifactId>javafx-graphics</artifactId>
+            <version>${javafx.version}</version>
+            <classifier>mac</classifier>
+        </dependency>
+    </dependencies>
+    <build>
+        <plugins>
+            <plugin>
+                <artifactId>maven-assembly-plugin</artifactId>
+                <version>${testVersion}</version>
+                <executions>
+                    <execution>
+                        <id>assembly</id>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>single</goal>
+                        </goals>
+                        <configuration>
+                            <descriptors>
+                                <descriptor>src/main/assembly/bin.xml</descriptor>
+                            </descriptors>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+        </plugins>
+    </build>
+</project>
diff --git a/src/it/projects/dependency-sets/massembly-969/src/main/assembly/bin.xml b/src/it/projects/dependency-sets/massembly-969/src/main/assembly/bin.xml
new file mode 100644
index 00000000..90df88a7
--- /dev/null
+++ b/src/it/projects/dependency-sets/massembly-969/src/main/assembly/bin.xml
@@ -0,0 +1,53 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<assembly>
+  <id>bin</id>
+  <formats>
+    <format>dir</format>
+  </formats>
+  <includeBaseDirectory>false</includeBaseDirectory>
+  <dependencySets>
+    <dependencySet>
+      <unpack>false</unpack>
+      <scope>runtime</scope>
+      <outputDirectory></outputDirectory>
+      <useProjectArtifact>false</useProjectArtifact>
+      <includes>
+        <include>org.openjfx:javafx-base</include>
+        <include>org.openjfx:javafx-controls</include>
+        <include>org.openjfx:javafx-media</include>
+        <include>org.openjfx:javafx-web</include>
+        <include>org.openjfx:javafx-swing</include>
+        <include>org.openjfx:javafx-graphics:jar:linux</include>
+      </includes>
+      <excludes>
+        <exclude>org.openjfx:javafx-base:jar:mac</exclude>
+        <exclude>org.openjfx:javafx-base:jar:win</exclude>
+        <exclude>org.openjfx:javafx-controls:jar:mac</exclude>
+        <exclude>org.openjfx:javafx-controls:jar:win</exclude>
+        <exclude>org.openjfx:javafx-media:jar:mac</exclude>
+        <exclude>org.openjfx:javafx-media:jar:win</exclude>
+        <exclude>org.openjfx:javafx-web:jar:mac</exclude>
+        <exclude>org.openjfx:javafx-web:jar:win</exclude>
+        <exclude>org.openjfx:javafx-swing:jar:mac</exclude>
+        <exclude>org.openjfx:javafx-swing:jar:win</exclude>
+      </excludes>
+    </dependencySet>
+  </dependencySets>
+</assembly>
\ No newline at end of file
diff --git a/src/it/projects/dependency-sets/massembly-969/verify.groovy b/src/it/projects/dependency-sets/massembly-969/verify.groovy
new file mode 100644
index 00000000..4865bc7f
--- /dev/null
+++ b/src/it/projects/dependency-sets/massembly-969/verify.groovy
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.*;
+
+def expectedFilenames = [ "javafx-base-18.0.1.jar",
+  "javafx-controls-18.0.1-linux.jar",
+  "javafx-media-18.0.1-linux.jar",
+  "javafx-web-18.0.1.jar",
+  "javafx-base-18.0.1-linux.jar",
+  "javafx-graphics-18.0.1-linux.jar",
+  "javafx-swing-18.0.1.jar",
+  "javafx-web-18.0.1-linux.jar",
+  "javafx-controls-18.0.1.jar",
+  "javafx-media-18.0.1.jar",
+  "javafx-swing-18.0.1-linux.jar"
+]
+
+File assemblyBasedir = new File( basedir, "target/massembly-969-1-bin/" )
+
+assert assemblyBasedir.listFiles().length == expectedFilenames.size()
+
+for ( fileName in expectedFilenames )
+{
+  File file = new File( assemblyBasedir, fileName )
+  assert file.isFile() // exists and is file
+}
+
+// defined set vs listed set: same cardinality and all present: OK
+
+return true