From 43550681acbcc4954d90c6f147d461f0463eb1f9 Mon Sep 17 00:00:00 2001 From: Amolith Date: Wed, 29 Oct 2025 16:26:00 -0600 Subject: [PATCH] build(release): improve version scheme --- Taskfile.yaml | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/Taskfile.yaml b/Taskfile.yaml index fb10b4305a586eb892119437076e754197ba3a47..3513a68d03e4639a890372efb26b90f78b8a77bf 100644 --- a/Taskfile.yaml +++ b/Taskfile.yaml @@ -121,17 +121,11 @@ tasks: vars: UPSTREAM_VERSION: sh: git describe --tags --abbrev=0 upstream/main 2>/dev/null || echo "v0.0.0" - FORK_VERSION: - sh: | - UP=$(git describe --tags --abbrev=0 upstream/main 2>/dev/null | sed 's/^v//' || echo "0.0.0") - MAJOR=$(echo $UP | cut -d. -f1) - MINOR=$(echo $UP | cut -d. -f2) - PATCH=$(echo $UP | cut -d. -f3) - NEXT_PATCH=$((PATCH + 1)) - # Count existing fork tags for this base version - EXISTING=$(git tag -l "v$MAJOR.$MINOR.$NEXT_PATCH" "v$MAJOR.$MINOR.$((NEXT_PATCH+1))" "v$MAJOR.$MINOR.$((NEXT_PATCH+2))" | wc -l) - echo "v$MAJOR.$MINOR.$((NEXT_PATCH + EXISTING))" - TAG: "{{.FORK_VERSION}}" + EXISTING_FORK_TAGS: + sh: git tag -l "{{.UPSTREAM_VERSION}}-fork.*" | wc -l + NEXT_NUM: + sh: echo $(({{.EXISTING_FORK_TAGS}} + 1)) + TAG: "{{.UPSTREAM_VERSION}}-fork.{{.NEXT_NUM}}" prompt: "Create fork release {{.TAG}}?" preconditions: - sh: '[ $(git symbolic-ref --short HEAD) = "dev" ]' @@ -144,3 +138,5 @@ tasks: - git tag -a {{.TAG}} - git push soft {{.TAG}} - echo "Released {{.TAG}}" + - go list -m git.secluded.site/crush@{{.TAG}} > /dev/null + - echo "Module proxy notified"