Skip to content

Commit

Permalink
feat: new version
Browse files Browse the repository at this point in the history
  • Loading branch information
Delyc committed Aug 26, 2024
1 parent f075df1 commit f14d4c0
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions .github/workflows/build-push-fe-docker-hub.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,16 @@ jobs:
- name: Determine next version
id: determine_version
run: |
# Get the latest tag
LATEST_TAG=$(git describe --tags --abbrev=0)
# Calculate next version
# Check if any tags exist
if git tag -l | grep -q '^v'; then
# Get the latest tag
LATEST_TAG=$(git describe --tags --abbrev=0)
else
# If no tags, set the initial tag
LATEST_TAG='v0.0.0'
fi
# Run semantic-release to get the next version
NEXT_VERSION=$(npx semantic-release --dry-run | grep 'Next version' | awk '{print $NF}')
echo "NEXT_VERSION=${NEXT_VERSION}" >> $GITHUB_ENV
Expand Down

0 comments on commit f14d4c0

Please sign in to comment.