Skip to content

Commit

Permalink
devonfw#523: exclude files from wrong OS (devonfw#562)
Browse files Browse the repository at this point in the history
  • Loading branch information
hohwille authored Aug 27, 2024
1 parent 3a50488 commit d46fd0d
Show file tree
Hide file tree
Showing 5 changed files with 46 additions and 12 deletions.
23 changes: 19 additions & 4 deletions cli/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,13 @@
<configuration>
<outputDirectory>${project.build.directory}/package</outputDirectory>
<resources>
<!--
Maven filtering can resolve ${...} variables in resource files.
However, in system folder there are resources that do not need filtering.
Some of them cannot be filtered by maven as they would cause such error:
InfoPlist.strings failed with MalformedInputException: Input length = 1
Therefore we exclude the system folder here from the resource.
-->
<resource>
<directory>src/main/package</directory>
<filtering>true</filtering>
Expand All @@ -136,6 +143,14 @@
<exclude>system/**/*</exclude>
</excludes>
</resource>
<!-- However, we then exclude system folder entirely so we need to added it here without filtering -->
<resource>
<directory>src/main/package</directory>
<filtering>false</filtering>
<includes>
<include>system/**/*</include>
</includes>
</resource>
</resources>
</configuration>
</execution>
Expand Down Expand Up @@ -232,22 +247,22 @@
<configuration>
<artifacts>
<artifact>
<file>${project.build.directory}/${project.artifactId}-${revision}-windows_x86_64.tar.gz</file>
<file>${project.build.directory}/${project.artifactId}-${revision}-windows-x64.tar.gz</file>
<type>tar.gz</type>
<classifier>windows-x64</classifier>
</artifact>
<artifact>
<file>${project.build.directory}/${project.artifactId}-${revision}-linux_x86_64.tar.gz</file>
<file>${project.build.directory}/${project.artifactId}-${revision}-linux-x64.tar.gz</file>
<type>tar.gz</type>
<classifier>linux-x64</classifier>
</artifact>
<artifact>
<file>${project.build.directory}/${project.artifactId}-${revision}-osx_x86_64.tar.gz</file>
<file>${project.build.directory}/${project.artifactId}-${revision}-mac-x64.tar.gz</file>
<type>tar.gz</type>
<classifier>mac-x64</classifier>
</artifact>
<artifact>
<file>${project.build.directory}/${project.artifactId}-${revision}-osx_aarch_64.tar.gz</file>
<file>${project.build.directory}/${project.artifactId}-${revision}-mac-arm.tar.gz</file>
<type>tar.gz</type>
<classifier>mac-arm</classifier>
</artifact>
Expand Down
9 changes: 7 additions & 2 deletions cli/src/main/assembly/release-macos-13.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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>osx_x86_64</id>
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 https://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>mac-x64</id>
<formats>
<format>tar.gz</format>
</formats>
Expand All @@ -17,6 +17,11 @@
<fileSet>
<directory>${project.build.directory}/package</directory>
<outputDirectory>.</outputDirectory>
<excludes>
<exclude>**/*.bat</exclude>
<exclude>system/windows/**</exclude>
<exclude>system/linux/**</exclude>
</excludes>
</fileSet>
</fileSets>
</assembly>
9 changes: 7 additions & 2 deletions cli/src/main/assembly/release-macos-latest.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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>osx_aarch_64</id>
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 https://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>mac-arm</id>
<formats>
<format>tar.gz</format>
</formats>
Expand All @@ -17,6 +17,11 @@
<fileSet>
<directory>${project.build.directory}/package</directory>
<outputDirectory>.</outputDirectory>
<excludes>
<exclude>**/*.bat</exclude>
<exclude>system/windows/**</exclude>
<exclude>system/linux/**</exclude>
</excludes>
</fileSet>
</fileSets>
</assembly>
9 changes: 7 additions & 2 deletions cli/src/main/assembly/release-ubuntu-latest.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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>linux_x86_64</id>
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 https://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>linux-x64</id>
<formats>
<format>tar.gz</format>
</formats>
Expand All @@ -17,6 +17,11 @@
<fileSet>
<directory>${project.build.directory}/package</directory>
<outputDirectory>.</outputDirectory>
<excludes>
<exclude>**/*.bat</exclude>
<exclude>system/windows/**</exclude>
<exclude>system/mac/**</exclude>
</excludes>
</fileSet>
</fileSets>
</assembly>
8 changes: 6 additions & 2 deletions cli/src/main/assembly/release-windows-latest.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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>windows_x86_64</id>
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 https://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>windows-x64</id>
<formats>
<format>tar.gz</format>
</formats>
Expand All @@ -17,6 +17,10 @@
<fileSet>
<directory>${project.build.directory}/package</directory>
<outputDirectory>.</outputDirectory>
<excludes>
<exclude>system/mac/**</exclude>
<exclude>system/linux/**</exclude>
</excludes>
</fileSet>
</fileSets>
</assembly>

0 comments on commit d46fd0d

Please sign in to comment.