Skip to content

Commit

Permalink
Updating build to be reproducible
Browse files Browse the repository at this point in the history
Multiple builds (without changes) will produce the same output (e.g. the hash of the jars will be identical)
  • Loading branch information
bdemers committed Mar 23, 2023
1 parent 52a5a06 commit be5e39b
Showing 1 changed file with 32 additions and 3 deletions.
35 changes: 32 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
</repositories>

<properties>

<project.build.outputTimestamp>2023-03-17T00:00:00Z</project.build.outputTimestamp>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<arguments/>

Expand Down Expand Up @@ -452,7 +452,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.2.1</version>
<version>3.2.3</version>
<configuration>
<shadedClassifierName>deprecated</shadedClassifierName>
<shadedArtifactAttached>true</shadedArtifactAttached>
Expand Down Expand Up @@ -592,10 +592,39 @@
<autoReleaseAfterClose>false</autoReleaseAfterClose>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<version>3.2.0</version>
<executions>
<execution>
<!-- Rebuilding the manifest with the maven-bundle-plugin produces different results
https://issues.apache.org/jira/browse/FELIX-6603
Deleting the previously generated manifest is a temporary workaround.
-->
<id>bundle-manifest-fix</id>
<phase>process-resources</phase>
<goals>
<goal>clean</goal>
</goals>
<configuration>
<excludeDefaultDirectories>true</excludeDefaultDirectories>
<filesets>
<fileset>
<directory>${project.build.outputDirectory}</directory>
<includes>
<include>META-INF/MANIFEST.MF</include>
</includes>
</fileset>
</filesets>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>3.3.0</version>
<version>5.1.8</version>
<executions>
<execution>
<id>bundle-manifest</id>
Expand Down

0 comments on commit be5e39b

Please sign in to comment.