Skip to content

Commit

Permalink
Fix check
Browse files Browse the repository at this point in the history
  • Loading branch information
evg-tso committed Sep 17, 2024
1 parent f3354b5 commit 963a0a6
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,15 @@ jobs:
VERSION=$(./mvnw help:evaluate -Dexpression=project.version -q -DforceStdout)
echo "VERSION=$VERSION" >> $GITHUB_ENV
- name: Validate Version with SNAPSHOT Suffix Check
- name: Validate Version with Suffix Check
if: endsWith(env.VERSION, '-SNAPSHOT')
run: echo "Version ${{ env.VERSION }} ends with -SNAPSHOT. Proceeding..."

- name: Fallback for Non-SNAPSHOT
if: "!endsWith(env.VERSION, '-SNAPSHOT')"
run: |
if [[ endsWith(env.VERSION, '-SNAPSHOT') ]]; then
echo "Version ${{ env.VERSION }} is valid. Proceeding..."
else
echo "Expected SNAPSHOT version but found ${{ env.VERSION }}. Failing..."
exit 1
fi
echo "Expected SNAPSHOT version but found ${{ env.VERSION }}. Failing..."
exit 1
build:
needs: pre_build
Expand Down

0 comments on commit 963a0a6

Please sign in to comment.