Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Maven build ermöglichen und automatisieren #614

Open
wants to merge 56 commits into
base: feature-3.1.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
88769ce
Update 457 Korrigiert (#655)
lenilsas Feb 10, 2025
9c80f83
feat: maven build
tobidope Jan 25, 2025
0b59e37
Zwischenstand eingecheckt
tobidope Jan 26, 2025
afd1cf5
Zwischenstand eingecheckt
tobidope Jan 27, 2025
aa5180f
Erstelle jameica plugin zip
Jan 27, 2025
3331d23
plugin Erstellung korrigiert
Jan 27, 2025
fd8559d
Manifest anpassen
tobidope Jan 27, 2025
2a5b4b9
Manifest schreiben
tobidope Jan 27, 2025
b15be6b
Umbenannt
tobidope Jan 27, 2025
ddea2b3
.classpath wieder zurückgesetzt
tobidope Jan 27, 2025
e9033e8
swt os typ per property auswählbar
tobidope Jan 27, 2025
65bf062
Alte Verzeichnisstruktur hergestellt
tobidope Jan 27, 2025
4586bf3
chmod korrigiert
Jan 28, 2025
8b4acba
chmod korrigiert
Jan 28, 2025
93d9c48
Änderungen rückgängig gemacht
Jan 28, 2025
c4243d8
reusable-build.yml umstellen
tobidope Jan 28, 2025
0c7f93a
buildcheck.yml umstellen
tobidope Jan 28, 2025
0814007
Nächster Versuch
tobidope Jan 28, 2025
dfb4105
Nächster Versuch
tobidope Jan 28, 2025
e6bb886
Noch ein Tippfehler
tobidope Jan 28, 2025
dd05fb6
--batch-mode
tobidope Jan 28, 2025
d73682f
reusable-build.yml nutzt nur setup-build.xml als cache key
tobidope Jan 28, 2025
2044afd
Jetzt mit Berechnung des hash keys
tobidope Jan 28, 2025
b1d7b80
nightly angepasst, würde neu einen snapshot erzeugen
tobidope Jan 28, 2025
cee3a02
pom resource filtering wieder deaktiviert
tobidope Jan 28, 2025
7905ad5
release.yml angepasst
tobidope Jan 28, 2025
d1cb7e6
release.yml falscher Pfad für release files
tobidope Jan 28, 2025
3f8768d
Formatierung korrigiert
tobidope Jan 28, 2025
a3726b7
cache inklusive maven build mit pom.xml nehmen bei cache miss
tobidope Jan 28, 2025
e489b00
Alle lokalen libs und ant entfernt
tobidope Jan 29, 2025
c57c185
restore-key angepasst, weil kein cache gefunden wurde
tobidope Jan 29, 2025
89dd5eb
Überall restore-key angepasst
tobidope Jan 29, 2025
5f0ebd9
Version automatisch in plugin.xml übernehmen
tobidope Jan 29, 2025
a72f299
Eindeutige ids in github actions
tobidope Jan 29, 2025
6003c26
Rebase fixen
tobidope Jan 31, 2025
aa1ab8b
Entpacken der plugin.zip ins target an verify gebunden
tobidope Feb 2, 2025
a492c6d
Run config für Idea eingecheckt
tobidope Feb 3, 2025
0ca0bf8
IDEA Projektfile automatisch bereitstellen
tobidope Feb 4, 2025
df3bfa8
reusable-build.yml auf neuen maven lifecycle angepasst
tobidope Feb 4, 2025
d11657e
jameica Projekt angepasst
tobidope Feb 4, 2025
f1db21d
Eclipse auf Maven umgestellt
tobidope Feb 4, 2025
869b492
Maven wrapper hinzugefügt, damit ein lokales maven nicht notwendig ist
tobidope Feb 4, 2025
d1d515c
Build auf maven wrapper umgestellt
tobidope Feb 4, 2025
d6ce8c1
jameica.iml automatisch auf build der aktuellen version zeigen lassen
tobidope Feb 4, 2025
29fd1b8
buildcheck immer laufen lassen und mvnw executable bit gesetzt
tobidope Feb 4, 2025
c3d024f
Eclipse Launcher einbinden
tobidope Feb 8, 2025
255b1c5
Leerzeile am Ende eingebunden
tobidope Feb 8, 2025
463648d
Zwischenstand: Dokumentation angepasst
tobidope Feb 9, 2025
01c9450
Dokumentation erweitert
tobidope Feb 9, 2025
d97f860
Java 11 Verwendung angepasst
tobidope Feb 9, 2025
8102234
Java 11 Verwendung angepasst
tobidope Feb 9, 2025
a5f02e1
Auf compiler release umgestellt
tobidope Feb 9, 2025
e788529
Unnötiges property entfernt
tobidope Feb 9, 2025
293b954
Neue Hibiscus Version eingebunden
tobidope Feb 9, 2025
cb941c3
Version auf upstream angepasst
tobidope Feb 9, 2025
0df89ee
Auf neue jameica version angepasst
tobidope Feb 12, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 17 additions & 31 deletions .classpath
Original file line number Diff line number Diff line change
@@ -1,37 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry excluding="fonts/*|holidays/*|img/*|lang/*|liquibase/*|main/*" including="**/*.java" kind="src" output="target/classes" path="src">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="src" path="junit/src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry exported="true" kind="src" path="/jameica"/>
<classpathentry kind="lib" path="lib/nc.jar"/>
<classpathentry exported="true" kind="lib" path="lib/javax.mail-1.6.2.jar"/>
<classpathentry combineaccessrules="false" exported="true" kind="src" path="/hibiscus"/>
<classpathentry exported="true" kind="lib" path="lib/activation.jar"/>
<classpathentry exported="true" kind="lib" path="/hibiscus/lib/obantoo-bin-2.1.12.jar"/>
<classpathentry exported="true" kind="lib" path="lib/bsh-core-2.0b4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/csvjdbc-1.0.40.jar"/>
<classpathentry exported="true" kind="lib" path="lib/itext-hyph-xml.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jollyday-0.5.10.jar"/>
<classpathentry exported="true" kind="lib" path="lib/joda-time-2.12.7.jar"/>
<classpathentry exported="true" kind="lib" path="lib/snakeyaml-2.2.jar"/>
<classpathentry exported="true" kind="lib" path="/jameica/lib/swt/win64/swt.jar" sourcepath="/jameica/lib.src/swt/linux/swt.src.zip"/>
<classpathentry exported="true" kind="lib" path="lib/junit-4.13.2.jar"/>
<classpathentry exported="true" kind="lib" path="lib/javase-3.5.3.jar"/>
<classpathentry exported="true" kind="lib" path="lib/core-3.1.0.jar"/>
<classpathentry exported="true" kind="lib" path="/jameica/lib/de_willuhn_ds/de_willuhn_ds.jar"/>
<classpathentry exported="true" kind="lib" path="/hibiscus/lib/super-csv-2.4.0.jar"/>
<classpathentry exported="true" kind="lib" path="/hibiscus/lib/itext-pdfa-5.5.2.jar"/>
<classpathentry exported="true" kind="lib" path="/hibiscus/lib/itextpdf-5.5.2.jar"/>
<classpathentry exported="true" kind="lib" path="lib/freemarker-2.3.33.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jackson-core-2.17.2.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jsoup-1.18.1.jar"/>
<classpathentry exported="true" kind="lib" path="lib/vinnie-2.0.2.jar"/>
<classpathentry exported="true" kind="lib" path="lib/ez-vcard-0.12.1.jar"/>
<classpathentry exported="true" kind="lib" path="/hibiscus/lib/pdfbox/pdfbox-3.0.2.jar"/>
<classpathentry kind="lib" path="lib/xmpbox-3.0.3.jar"/>
<classpathentry kind="lib" path="lib/jakarta.activation-api-2.1.3.jar"/>
<classpathentry kind="lib" path="lib/dom4j-2.1.4.jar"/>
<classpathentry kind="lib" path="lib/mustang-2.16.0.jar"/>
<classpathentry kind="output" path="bin"/>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/classes"/>
</classpath>
44 changes: 21 additions & 23 deletions .github/workflows/buildcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,8 @@ name: OpenJVerein build check

on:
pull_request:
types: [opened, reopened, synchronize, edited]
paths:
- 'plugin.xml'
- 'build/**'
- 'lib/**'
- 'lib.src/**'
- 'src/**'
types: [ opened, reopened, synchronize, edited ]
push:
jobs:
call-reusable-workflow:
uses: ./.github/workflows/reusable-build.yml
Expand All @@ -20,21 +15,24 @@ jobs:
needs: call-reusable-workflow
runs-on: ubuntu-latest
steps:
- name: Restore cached tags and jars
id: cache-tags-jars
uses: actions/cache@v4
with:
path: |
./cached-tags
jameica
hibiscus
key: ${{ runner.os }}-${{ github.repository_id }}
- name: Checkout openjverein
uses: actions/checkout@v4

- name: Checkout openjverein
uses: actions/checkout@v4
with:
path: jverein
- name: Restore cache
id: restore-cache
uses: actions/cache/restore@v4
with:
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
cache-${{ hashFiles('setup-build.xml') }}

- name: Build openjverein plugin
working-directory: ./
run: ant -noinput -buildfile jverein/build/build.xml compile
- name: Build openjverein plugin
run: ./mvnw --batch-mode --file pom.xml clean package

- name: Save cache
uses: actions/cache/save@v4
if: steps.restore-cache.outputs.cache-hit != 'true'
with:
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}-${{ hashFiles('**/pom.xml') }}
54 changes: 19 additions & 35 deletions .github/workflows/nightly-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,51 +18,35 @@ jobs:
needs: call-reusable-workflow
runs-on: ubuntu-latest
steps:
- name: Restore cached tags and jars
id: cache-tags-jars
uses: actions/cache@v4
with:
path: |
./cached-tags
jameica
hibiscus
key: ${{ runner.os }}-${{ github.repository_id }}

- name: Checkout openjverein
uses: actions/checkout@v4

- name: Restore cache
id: restore-cache
uses: actions/cache/restore@v4
with:
path: jverein
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
cache-${{ hashFiles('setup-build.xml') }}

Comment on lines +23 to 32
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hier könnte man sicher noch einiges nach reusable-build.yaml auslagern.

Copy link
Member Author

@tobidope tobidope Feb 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Der build hier nutzt einen anderen hash. Das kann man schlecht zusammenlegen

- name: Build openjverein plugin
id: openjverein
working-directory: ./
run: |
ant_output=$(ant -e -q -noinput -buildfile jverein/build/build.xml nightly)
echo ${ant_output}

ssa="SELECTED_VERSION="
ssb=".zip"
text="${ant_output#*${ssa}}"
text="${text%${ssb}*}.zip"
tmp_version=$(echo $text | sed -rn 's/^([^[:blank:]]*).*$/\1/p')

ssa="SELECTED_FILENAME="
text="${ant_output#*${ssa}}"
text="${text%${ssb}*}.zip"
tmp_filename=$(echo $text | sed -rn 's/^([^[:blank:]]*).*$/\1/p')

ssa="SELECTED_PATH="
text="${ant_output#*${ssa}}"
text="${text%${ssb}*}.zip"
tmp_path=$(echo $text | sed -rn 's/^([^[:blank:]]*).*$/\1/p')

./mvnw --batch-mode --file pom.xml clean package
tmp_version=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
echo "selected_version=${tmp_version}" >> $GITHUB_OUTPUT
echo "selected_filename=${tmp_filename}" >> $GITHUB_OUTPUT
echo "selected_path=${tmp_path}" >> $GITHUB_OUTPUT

tmp_filename=$(basename "./target/jverein-*.zip")
builddatetime=$(date +'%Y-%m-%d %H:%M')
echo "### Version: ${tmp_version} | filename: ${tmp_filename} | build datetime: ${builddatetime}" >> $GITHUB_STEP_SUMMARY

- name: Save cache
uses: actions/cache/save@v4
if: steps.restore-cache.outputs.cache-hit != 'true'
with:
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}-${{ hashFiles('**/pom.xml') }}

# Update tag
- name: Tag repo
uses: richardsimko/update-tag@v1
Expand All @@ -77,5 +61,5 @@ jobs:
tag_name: ${{ steps.openjverein.outputs.selected_version }}
prerelease: true
name: Release ${{ steps.openjverein.outputs.selected_version }}
files: ./jverein/${{ steps.openjverein.outputs.selected_path }}
files: ./target/jverein-*.zip
generate_release_notes: false
63 changes: 27 additions & 36 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,57 +13,48 @@ jobs:
needs: call-reusable-workflow
runs-on: ubuntu-latest
steps:
- name: Restore cached tags and jars
id: cache-tags-jars
uses: actions/cache@v4
with:
path: |
./cached-tags
jameica
hibiscus
key: ${{ runner.os }}-${{ github.repository_id }}

- name: Checkout openjverein
uses: actions/checkout@v4

- name: Restore cache
id: restore-cache
uses: actions/cache/restore@v4
with:
path: jverein
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
cache-${{ hashFiles('setup-build.xml') }}

- name: Build openjverein plugin
id: openjverein
working-directory: ./
run: |
ant_output=$(ant -e -q -noinput -buildfile jverein/build/build.xml)
echo ${ant_output}

ssa="SELECTED_VERSION="
ssb=".zip"
text="${ant_output#*${ssa}}"
text="${text%${ssb}*}.zip"
tmp_version=$(echo $text | sed -rn 's/^([^[:blank:]]*).*$/\1/p')
tmp_version=$tmp_version

ssa="SELECTED_FILENAME="
text="${ant_output#*${ssa}}"
text="${text%${ssb}*}.zip"
tmp_filename=$(echo $text | sed -rn 's/^([^[:blank:]]*).*$/\1/p')

ssa="SELECTED_PATH="
text="${ant_output#*${ssa}}"
text="${text%${ssb}*}.zip"
tmp_path=$(echo $text | sed -rn 's/^([^[:blank:]]*).*$/\1/p')

./mvnw --batch-mode --file pom.xml clean package
tmp_version=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
echo "selected_version=${tmp_version}" >> $GITHUB_OUTPUT
echo "selected_filename=${tmp_filename}" >> $GITHUB_OUTPUT
echo "selected_path=${tmp_path}" >> $GITHUB_OUTPUT

tmp_filename=$(basename "./target/jverein-*.zip")
builddatetime=$(date +'%Y-%m-%d %H:%M')
echo "### Version: ${tmp_version} | filename: ${tmp_filename} | build datetime: ${builddatetime}" >> $GITHUB_STEP_SUMMARY

- name: Save cache
uses: actions/cache/save@v4
if: steps.restore-cache.outputs.cache-hit != 'true'
with:
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}-${{ hashFiles('**/pom.xml') }}

# Update tag
- name: Tag repo
uses: richardsimko/update-tag@v1
with:
tag_name: ${{ steps.openjverein.outputs.selected_version }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ steps.openjverein.outputs.selected_version }}
prerelease: false
name: Release ${{ steps.openjverein.outputs.selected_version }}
files: ./jverein/${{ steps.openjverein.outputs.selected_path }}
files: ./target/jverein-*.zip
generate_release_notes: true
115 changes: 27 additions & 88 deletions .github/workflows/reusable-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,91 +7,30 @@ jobs:
setup-java-and-cache:
runs-on: ubuntu-latest
steps:
- name: Set up JDK for x64
uses: actions/setup-java@v4
with:
java-version: '11'
distribution: 'temurin'
architecture: x64

- name: Set env
id: setenvs
run: |
jameica_tag=$(git ls-remote --refs --tags --sort="-v:refname" https://github.com/willuhn/jameica.git V_\* | head -1 | cut -f 2 | cut -d / -f 3)
echo "jameica_tag=${jameica_tag}" >> $GITHUB_ENV
hibiscus_tag=$(git ls-remote --refs --tags --sort="-v:refname" https://github.com/willuhn/hibiscus.git V_\* | head -1 | cut -f 2 | cut -d / -f 3)
Comment on lines -20 to -22
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hier bestimmen wir die aktuellen release tags dynamisch. In der POM hast du sie hart kodiert. Kann man das auch dynamisieren? Sonst verlieren wir wieder Flexibilität.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Das macht den build aber nicht wiederholbar, da er vom Zustand externer Quellen abhängt. Ich würde vorschlagen renovate einzubauen und sehr bewusst die genutzte Version zu aktualisieren.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Das macht den build aber nicht wiederholbar, da er vom Zustand externer Quellen abhängt.

Da hast du Recht. Das ist jedoch für die nightly builds absolut relevant. Nicht, dass wir von den Quellen abhängig wären. Wir bräuchten die Libs von Jameica und Hibiscus. Wenn die in einem maven repository lägen, wäre das ideal. Da könnten zumindest die Releases liegen. Ich hatte auch schon versucht, über Repology die aktuelle Version zu bekommen. Da habe ich jedoch die Rest-API nicht richtig nutzen können. In #516 (comment) hatte ich zumindest mal das Fetching der Jars mit remotezip dokumentiert. Vielleicht ist das für diesen PR eine Möglichkeit? Zumindest braucht es für unsere Releases kein compile der nightlies von Jameica und Hibiscus. Das wäre nur für unser future-proof notwendig.

Ich würde vorschlagen renovate einzubauen.

Meinst du https://github.com/renovatebot/renovate?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ich meine genau das renovate. Das hat github-tags als data source. D.h. man kann es konfigurieren, automatisch einen pull reuqest zu stellen, wenn Jameica oder Hibiscus ein neue Version bereitstellen. Die baut dann natürlich auch und du siehst sofort, ob es noch baut.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ich habe übrigens auch schon mal getestet, die benötigten jars in das GitHub maven repository zu installieren, das funktioniert auch, und würde den tatsächlichen build step völlig unabhängig vom reusable-Build machen. Zum lokalen Test braucht man immer noch die Plugin.zip entpackt und es ist wirklich nett, direkt in den source von Jamaica zu schauen.

echo "hibiscus_tag=${hibiscus_tag}" >> $GITHUB_ENV
echo "### jameica_tag: ${jameica_tag} | hibiscus_tag: ${hibiscus_tag}"

- name: Restore cached tags and folders
id: cache-tags-jars
uses: actions/cache@v4
with:
path: |
./cached-tags
jameica
hibiscus
key: ${{ runner.os }}-${{ github.repository_id }}

- name: Load cached tags
id: load-cache
run: |
if [ -f ./cached-tags/jameica_tag ]; then
cached_jameica_tag=$(cat ./cached-tags/jameica_tag)
echo "cached_jameica_tag=${cached_jameica_tag}" >> $GITHUB_ENV
else
echo "cached_jameica_tag=" >> $GITHUB_ENV
fi
if [ -f ./cached-tags/hibiscus_tag ]; then
cached_hibiscus_tag=$(cat ./cached-tags/hibiscus_tag)
echo "cached_hibiscus_tag=${cached_hibiscus_tag}" >> $GITHUB_ENV
else
echo "cached_hibiscus_tag=" >> $GITHUB_ENV
fi
echo "### cached_jameica_tag: ${cached_jameica_tag} | cached_hibiscus_tag: ${cached_hibiscus_tag}"

- name: Checkout jameica
if: ${{ env.cached_jameica_tag != env.jameica_tag }}
uses: actions/checkout@v4
with:
repository: willuhn/jameica
path: jameica
ref: ${{ env.jameica_tag }}

- name: Build jameica jar
if: ${{ env.cached_jameica_tag != env.jameica_tag }}
working-directory: ./
run: |
ant -noinput -buildfile jameica/build/build.xml jar
find jameica/releases/ -type f -name jameica.jar -exec cp {} jameica/releases/jameica-lib.jar \;

- name: Checkout hibiscus
if: ${{ env.cached_hibiscus_tag != env.hibiscus_tag }}
uses: actions/checkout@v4
with:
repository: willuhn/hibiscus
path: hibiscus
ref: ${{ env.hibiscus_tag }}

- name: Build hibiscus jar
if: ${{ env.cached_hibiscus_tag != env.hibiscus_tag }}
working-directory: ./
run: |
ant -noinput -buildfile hibiscus/build/build.xml jar
find hibiscus/releases/ -type f -name hibiscus.jar -exec cp {} hibiscus/releases/hibiscus-lib.jar \;

- name: Create cache files and needed folders
run: |
mkdir -p ./cached-tags
echo "${{ env.jameica_tag }}" > ./cached-tags/jameica_tag
echo "${{ env.hibiscus_tag }}" > ./cached-tags/hibiscus_tag

- name: Cache tags and folders
uses: actions/cache@v4
if: always()
with:
path: |
./cached-tags
jameica
hibiscus
key: ${{ runner.os }}-${{ github.repository_id }}
- name: Set up JDK for x64
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
architecture: x64

- name: Checkout
uses: actions/checkout@v4

- name: Restore cache
id: restore-cache
uses: actions/cache/restore@v4
with:
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}

- name: Run setup-build.xml
if: steps.restore-cache.outputs.cache-hit != 'true'
run: ./mvnw --batch-mode --file setup-build.xml clean install

- name: Save cache
if: steps.restore-cache.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
path: ~/.m2/repository
key: cache-${{ hashFiles('setup-build.xml') }}
Loading