Skip to content

fix: exclude prerelease tags when finding latest version#37

Merged
avihut merged 1 commit intomasterfrom
fix/bump-version-exclude-prereleases
Jan 10, 2026
Merged

fix: exclude prerelease tags when finding latest version#37
avihut merged 1 commit intomasterfrom
fix/bump-version-exclude-prereleases

Conversation

@avihut
Copy link
Owner

@avihut avihut commented Jan 10, 2026

Summary

Fixes bump-version workflow to exclude prerelease tags (canary, beta) when determining the latest stable version.

Problem: The workflow was using git tag -l 'v*.*.*' | sort -V | tail -n1 which included prerelease tags like v0.2.0-canary.3. This caused the version to jump from v0.1.28 to v0.2.1 unexpectedly.

Solution: Add grep -v '-' to filter out tags containing hyphens (prerelease indicators).

- LATEST=$(git tag -l 'v*.*.*' | sort -V | tail -n1)
+ LATEST=$(git tag -l 'v*.*.*' | grep -v '-' | sort -V | tail -n1)

Test plan

  • After merge, next stable release should increment from v0.2.1 to v0.2.2 (not pick up canary/beta tags)

🤖 Generated with Claude Code

@avihut avihut merged commit 8f6aca5 into master Jan 10, 2026
@avihut avihut deleted the fix/bump-version-exclude-prereleases branch January 10, 2026 20:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant