Skip to content
Back to skills

Project Tag Version

ASecurity

Tag the release after a merge to main, computing the next semver tag with svu

  • 7 stars
  • 0 votes
  • 0 copies
  • 4 views
  • Added September 5, 2026
ai-agentsgobashgitapi

Works with

  • api

Security analysis

A100/100

Scanned November 29, 2026

npx -y skills add JasonWarrenUK/goblin-mode --skill project-tag_version --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Project Tag Version?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Project Tag Version
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/jasonwarrenuk-project-tag-version/badge)](https://www.skillsdirectory.com/skills/jasonwarrenuk-project-tag-version)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: "Project: Tag Version"
description: "Tag the release after a merge to main, computing the next semver tag with svu"
when_to_use: "When a merge to main has landed and the release should be tagged, or to report what bump is pending on a branch. Never tags at PR creation, mid-branch or on staging; releases are things that happened to main."
model: sonnet
effort: low
metadata:
  glyph: ᛊ
  family: project
  goblin-spinner: computing the bump|tagging|reading the commits
disable-model-invocation: true
allowed-tools: ["Bash(svu:*)", "Bash(git:*)", "Bash(~/.claude/library/scripts/safe-version-next.sh:*)"]
disallowed-tools: ["Bash(git push --tags:*)"] # publishes every stray local tag; this skill pushes single tags only
---

# Tag the release with `svu`

[`svu`](https://github.com/caarlos0/svu) derives the next semver tag from conventional-commit history. It only computes the version; it never commits, pushes or merges.

**Hard rule:** the tag always comes from `safe-version-next.sh`, never bare `svu next`. The script is identical to `svu next` except it refuses to cross 0.x → 1.x automatically; declaring the API stable is a human decision, so it emits a 0.x minor bump instead (and says so on stderr; relay the note when it fires). Later major bumps pass through. A renamed plugin with nothing tagged under its new name continues the old name's series, found through the `renames` map in `.claude-plugin/marketplace.json`; its `plugin.json` declaring `1.0.0` counts as the human decision, so the rename itself can cross into 1.x.

## The one tagging moment: merge to `main`

A release is a commit on `main`; nothing else gets a tag. No tagging at PR creation (the version would point at unreviewed commits, race other open PRs and burn numbers on branches that may never merge), no tagging mid-branch, no plain-semver tags on `staging` (two branches sharing one version sequence means the same number can point at different commits).

From an **up-to-date main checkout** (`git checkout main && git pull` first if there's any doubt; tagging from a feature branch or stale main tags the wrong commit):

```bash
TAG="$("$HOME"/.claude/library/scripts/safe-version-next.sh)" && git tag "$TAG" && git push origin "$TAG"
```

Push the single tag, never `git push --tags`; that publishes every local tag you've ever made, strays included.

Script exit codes: **3** = nothing to release (no version-bumping commits since the current tag): say so and stop, don't force a tag. **4** = omitted by policy: the repository's `.claude/versioning.json` lists this target in `omit-gh-tag`, so it is never tagged; say so and stop (`project-versioning_policy` shows and changes the policy). **2** = environment error; report it.

## Mid-branch: report, never tag

When a branch accumulates significant work, it's worth *saying* what's pending, as information, not an offer to tag. Detect the level by comparing `svu current` with the tag `safe-version-next.sh` prints, never bare `svu next`: in a 0.x series bare svu reports a breaking change as 1.0.0, which no merge will tag.

- Different major segment → major pending
- Same major, different minor → minor pending
- Only the patch segment changed → stay silent

Phrase it as a statement about the future merge:

```text
⬆️ minor bump pending: this branch will tag v1.3.0 when it merges to main.
```

On a **stacked child branch** (its PR's base is another branch, not main), the next tag counts the unmerged parent layers' commits too: report the pending bump as belonging to the stack as a whole ("this stack will tag..."), never to this layer alone.

Nothing mid-branch ever creates a tag. The tag happens once, on main, after the merge (`pr-land` runs this exact sequence as its Step 3).

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.