Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions Taskfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -306,3 +306,43 @@ tasks:
- defer:
task: stop-db
- go test -count=1 -tags integration $(go list ./... | grep -v "quickstart") -v -failfast

patch:
desc: Bump patch version (e.g. v0.83.16 → v0.83.17) and push the tag
cmds:
- |
current=$(git describe --tags --abbrev=0)
IFS='.' read -r major minor patch <<< "${current#v}"
patch=$((patch + 1))
next="v${major}.${minor}.${patch}"
echo "Bumping ${current} → ${next}"
git tag -a "${next}" -m "${next}"
git push origin "${next}"

minor:
desc: Bump minor version (e.g. v0.83.16 → v0.84.0) and push the tag
cmds:
- |
current=$(git describe --tags --abbrev=0)
IFS='.' read -r major minor patch <<< "${current#v}"
minor=$((minor + 1))
next="v${major}.${minor}.0"
echo "Bumping ${current} → ${next}"
git tag -a "${next}" -m "${next}"
git push origin "${next}"

alpha:
desc: Bump to next alpha pre-release (e.g. v0.83.16 → v0.83.16-alpha.0, or v0.83.16-alpha.0 → v0.83.16-alpha.1)
cmds:
- |
current=$(git describe --tags --abbrev=0)
base="${current%%-alpha.*}"
if [[ "${current}" == *-alpha.* ]]; then
alpha_num="${current##*-alpha.}"
next="${base}-alpha.$((alpha_num + 1))"
else
next="${base}-alpha.0"
fi
echo "Bumping ${current} → ${next}"
git tag -a "${next}" -m "${next}"
git push origin "${next}"
Loading