Skip to content

Commit

Permalink
Merge branch 'main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
NickSneo committed Aug 12, 2024
2 parents 03a6057 + 5001ac8 commit 1423a90
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,25 @@ jobs:
uses: actions/checkout@v4
with:
submodules: recursive
# Check whether gradle.properties version has been released already
# This prevents accidently publish same version
# Only check binary for arithmetic as all published together and arithmetic is the first
- name: Check existing release
run: |
# Check whether version contains SNAPSHOT
grep "^version" gradle.properties | grep -q SNAPSHOT || {
# Extract version from gradle.properties
VERSION=$(grep "^version" gradle.properties | sed 's|^version=\(.*\)$|\1|g')
echo "Query for version [$VERSION]"
curl --head -L --silent --output /dev/null --fail "$ART_URL/$VERSION" && {
echo "ERROR: Binary arithmetic already exists for version [$VERSION]"
echo "ERROR: Blocking republishing same version to the Besu Artifactory"
echo "url $ART_URL/$VERSION"
exit 1
}
}
env:
ART_URL: 'https://hyperledger.jfrog.io/artifactory/besu-maven/org/hyperledger/besu/arithmetic'
- name: Build
run: ./build.sh
- uses: actions/upload-artifact@v3.1.0
Expand Down

0 comments on commit 1423a90

Please sign in to comment.