Skip to content

Commit

Permalink
Use cut for version parts
Browse files Browse the repository at this point in the history
No need in extra `MAJOR` & `MINOR` for our logic
  • Loading branch information
artembilan committed Nov 6, 2024
1 parent d29d129 commit 21c0cf9
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions .github/workflows/spring-finalize-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,10 @@ jobs:
then
NEXT_VERSION=${NEXT_VERSION/-*}
else
MAJOR=${NEXT_VERSION/.*}
MINOR_PATCH=${NEXT_VERSION#*.}
MINOR=${MINOR_PATCH/.*}
PATCH_HOT_FIX=${MINOR_PATCH#*.}
PATCH=${PATCH_HOT_FIX/.*}
MAJOR_MINOR=$(echo "$NEXT_VERSION" | cut -d '.' -f1-2)
PATCH=$(echo "$NEXT_VERSION" | cut -d '.' -f3)
PATCH=$((PATCH+1))
NEXT_VERSION=$MAJOR.$MINOR.$PATCH
NEXT_VERSION=$MAJOR_MINOR.$PATCH
fi
NEXT_VERSION=${NEXT_VERSION}-SNAPSHOT
Expand Down

0 comments on commit 21c0cf9

Please sign in to comment.