feat(license): Kein Verzeichniswechsel, suche BOM-File in Standardpfaden

Bei (bedingtem) Verzeichnis wären absolute Dateipfade sinnvoll, damit der Artefact-Export funktioniert.
Ein Verzeichniswechsel scheint aber garnicht notwendig zu sein, wenn die BOM-Datei korrekt/absolut angegeben ist.
This commit is contained in:
Timo Beller 2022-07-13 17:25:04 +02:00
parent a214cccafd
commit 943537f019

View File

@ -8,9 +8,15 @@
INVALID_LICENSE_ADOC_FILE: invalid-licenses.adoc
NUMBER_OF_ALLOWED_FAILURES: 0
script:
# If bom-file does not exist, search for it in default-maven directory
- >
if [ "$BACKEND_DIR" != "" ]; then
cd $BACKEND_DIR
if [[ ! -f "$BOM_FILE" && -f "$BACKEND_DIR/target/bom.json" ]]; then
export BOM_FILE=$BACKEND_DIR/target/bom.json
fi
# If bom-file does not exist, search for it in default-gradle directory
- >
if [[ ! -f "$BOM_FILE" && -f "$BACKEND_DIR/build/reports/bom.json" ]]; then
export BOM_FILE=$BACKEND_DIR/build/reports/bom.json
fi
- export NUMBER_OF_INVALID_LICENSES=0
- export INVALID_BOM_FILE=invalid-bom.json