Add test setup for reproducible builds
Just run test.sh (Once parent 36 is out)
diff --git a/pom.xml b/pom.xml
index 8881b65..6824113 100644
--- a/pom.xml
+++ b/pom.xml
@@ -23,7 +23,7 @@
<parent>
<groupId>org.apache.sling</groupId>
<artifactId>sling-bundle-parent</artifactId>
- <version>35</version>
+ <version>36</version>
<relativePath />
</parent>
@@ -52,6 +52,7 @@
<properties>
<site.jira.version.id>12314252</site.jira.version.id>
<sling.java.version>8</sling.java.version>
+ <project.build.outputTimestamp>2019-10-02T08:04:00Z</project.build.outputTimestamp>
</properties>
<dependencies>
diff --git a/test.sh b/test.sh
new file mode 100755
index 0000000..2f6c8cc
--- /dev/null
+++ b/test.sh
@@ -0,0 +1,35 @@
+#!/bin/sh -e
+
+jar_base=org.apache.sling.api-2.22.1-SNAPSHOT.jar
+
+function log {
+
+ echo "|-----------------------------|"
+ echo "| ${@}"
+ echo "|-----------------------------|"
+
+}
+
+function run_build {
+ log "Building jar #${1}"
+ rm -rf ${1}-${jar_base} ${1}
+ mkdir ${1}
+ mvn -q clean install -Drat.skip=true
+ mv target/${jar_base} ${1}-${jar_base}
+ pushd ${1}
+ jar xf ../${1}-${jar_base}
+ popd
+}
+
+run_build 1
+run_build 2
+
+log "Generating diff"
+
+diff -ur 1 2
+
+if [ $? -eq 0 ];
+ log "SUCCESS"
+else
+ log "FAILURE, please check above diff"
+fi