Skip to content

Commit

Permalink
Avoid duplicates in update-extension-dependencies.sh
Browse files Browse the repository at this point in the history
I don't know how we can end up with duplicates in the JSON descriptor
but let's make sure it doesn't affect our build.
  • Loading branch information
gsmet committed Aug 1, 2024
1 parent 8039b4e commit 63d1ee7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions update-extension-dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ then
echo ''
echo 'Building bom-descriptor-json...'
echo ''
mvn -q -e -Dscan=false clean package -f "${PRG_PATH}/devtools/bom-descriptor-json" -Denforcer.skip $*
./mvnw -q -e -Dscan=false clean package -Dno-build-cache -f "${PRG_PATH}/devtools/bom-descriptor-json" -Denforcer.skip $*
else
read -n1 -p 'Build the entire project with relocations? [y/n] ' ANSWER
echo ''
Expand All @@ -23,7 +23,7 @@ else
echo ''
echo 'Building entire project with relocations...'
echo ''
mvn -q -e -Dscan=false -Dquickly -Dno-test-modules -Prelocations -T0.8C -f "${PRG_PATH}" $*
./mvnw -q -e -Dscan=false -Dquickly -Dno-build-cache -Dno-test-modules -Prelocations -T0.8C -f "${PRG_PATH}" $*
else
echo ''
echo 'Aborted!'
Expand Down Expand Up @@ -60,8 +60,9 @@ export LANG="C"

# note: quarkus-amazon-common was removed from this repo without a relocation
ARTIFACT_IDS=$(cd "${PRG_PATH}" && grep '^ "artifact"' devtools/bom-descriptor-json/target/quarkus-bom-quarkus-platform-descriptor-*.json \
| grep -Eo 'quarkus-[a-z0-9-]+' | grep -v quarkus-amazon-common | sort)
| grep -Eo 'quarkus-[a-z0-9-]+' | grep -v quarkus-amazon-common | sort -u)
set -o pipefail

if [ -z "${ARTIFACT_IDS}" ]
then
echo -e '\033[0;31mError:\033[0m Could not find any artifact-ids. Please check the grep command. ' 1>&2
Expand Down

0 comments on commit 63d1ee7

Please sign in to comment.