---
name: release-tag
description: This skill should be used when the user asks to "create a release tag", "bump version", "tag a release", "release major/minor/patch", "bump major", "bump minor", "bump patch", "create version tag", or "/release-tag". Bumps semantic version, invokes changelog, and creates annotated git tag.
title: release-tag
canonical_url: https://skilld.dev/gh/utkudarilmaz/claude-code-setup/release-tag
last_updated: 2026-11-23T08:06:03.000Z
---

> Index of every page on this site: [llms.txt](https://skilld.dev/llms.txt)

> **Skill from skilld.dev.** Follow the user's requested action.
> If the user asked to fork this Skill, follow the fork workflow below. Do not execute the Skill instructions while copying it.
> Otherwise, follow the instructions below for this session. You do not need to install anything.
>
> If the user asked to install this Skill, run `npx skilld install utkudarilmaz/claude-code-setup/release-tag`. Install writes the Skill files into the project, so every session loads them.
>
> ## Fork workflow
>
> A fork creates an editable local Skill with its original author and licence. The request authorizes copying and local installation.
> 1. Check `./skills/release-tag`, the project lockfile, and selected Agent targets together. If the local directory or installed Skill exists, stop. Never overwrite an existing directory or Agent target.
> 2. Read [source metadata](https://skilld.dev/api/v1/skills/utkudarilmaz/claude-code-setup/release-tag) once. Use sourceUrl, sourceCommit, skillPath, sourceGone, and license. If the source is gone or its path is missing, stop. If license is null, read licence files at the source commit.
> 3. Fetch only the source commit into a temporary Git repository. Do not clone full history. Derive repository_url from sourceUrl, including repository renames. If sourceCommit is absent, resolve the sourceUrl ref once. Set source_commit to that actual commit. Run these commands in one shell call:
>
> ```sh
> git init --quiet "$temporary_dir"
> git -C "$temporary_dir" fetch --quiet --depth=1 "$repository_url" "$source_commit"
> git -C "$temporary_dir" checkout --quiet --detach FETCH_HEAD
> ```
>
> Read applicable licence declarations and notices at that commit. If copying is not permitted, report the restriction and stop.
> 4. Inspect source entries together, then copy the directory containing skillPath into `./skills/release-tag`. Use the user's path if selected. Keep the original SKILL.md, relative links, scripts, binary assets, and executable modes. Exclude .git metadata. Reject symlinks and paths outside the Skill directory. After checking entries, use cp -a where available. A regular source directory needs no custom copy script. Do not save this page wrapper as SKILL.md.
> Preserve author credit, notices, and applicable licence files from repository or parent directories. Add PROVENANCE.md with the Skill page, source URL, actual commit, original path, and licence. Retain any existing PROVENANCE.md and record new provenance separately. Batch source inspection, copying, and provenance work where practical.
> 5. In the project root, run `skilld install ./skills/release-tag --mode copy --plain`. If skilld is unavailable, use `npx skilld install ./skills/release-tag --mode copy --plain`. This known command needs no help lookup. Install does not support --json. Use detected Agent targets, or add --agent for the targets the user selected. Install the local path, never the upstream selector. If installation fails, preserve the local copy and report the exact failure.
> 6. Confirm the local lockfile source and installed Agent copies once. Report the local path, actual commit, and Agent targets. After edits, reinstall the same local path. Upstream updates must not replace it. Do not publish or push unless the user asks.

# Release Tag Skill

## Purpose

Bump a semantic version tag, update CHANGELOG.md via the `/changelog` skill, and create an annotated git tag with a commit summary message. Keeps the tag prefix the repository already uses (`1.2.3` or `v1.2.3`) and handles initial tagging from `0.0.0` when no tags exist.

## Invocation

### `/release-tag <major|minor|patch>`

A bump type argument is **required**. Reject invocation without one.

```
/release-tag patch   # 1.2.3 -> 1.2.4, v1.2.3 -> v1.2.4
/release-tag minor   # 1.2.3 -> 1.3.0
/release-tag major   # 1.2.3 -> 2.0.0
```

## Workflow

Execute these steps sequentially:

### Step 1: Determine current version

```bash
git tag --sort=-version:refname | head -1
```

Find the tag prefix from the latest tag:

- Tag starts with `v` (for example `v1.2.3`): the prefix is `v`
- Otherwise (for example `1.2.3`): there is no prefix

If no tags exist, use `0.0.0` as the base version and ask the user whether the first tag should have a `v` prefix. Go modules need the `v` prefix, so recommend it when the repository has a `go.mod` file.

### Step 2: Calculate new version

Strip the prefix, parse the current version into `major.minor.patch` components and apply the bump:

| Bump type | Rule |
|-----------|------|
| `patch` | Increment patch, keep major and minor |
| `minor` | Increment minor, reset patch to 0, keep major |
| `major` | Increment major, reset minor and patch to 0 |

Add the prefix back to get the new tag name. Use this full tag name as `<new-version>` in every later step.

Report to the user: `Bumping <current> -> <new>`

### Step 3: Verify clean working tree

```bash
git status --porcelain
```

If the working tree has uncommitted changes, **stop and report** the issue. Do not proceed with a dirty tree. The user must commit or stash changes first.

### Step 4: Invoke changelog

Use the Skill tool to invoke `core:changelog`. This updates CHANGELOG.md with the latest changes.

After changelog completes, stage and commit the changelog update:

```bash
git add CHANGELOG.md
git commit -m "docs: update changelog for <new-version>"
```

### Step 5: Build tag message

Gather commits since the last tag (or all commits if no previous tag):

```bash
git log <last-tag>..HEAD --oneline
# or if no previous tag:
git log --oneline
```

Group commits by conventional commit type (feat, fix, docs, refactor, etc.) for the tag message. Format as a readable summary.

### Step 6: Create annotated tag

```bash
git tag -a <new-version> -m "<tag-message>"
```

Report success: `Created tag <new-version>`

### Step 7: Push

Push the changelog commit and the tag in one atomic push, so the tag never reaches the remote without its commit:

```bash
git push --atomic origin HEAD <new-version>
```

Never force push. If the push is rejected, stop and report it; the local tag stays.

## Rules

- **Keep the tag prefix**: Follow the prefix of the latest tag; never add or drop a `v` on your own
- **Annotated tags only**: Always use `git tag -a`, never lightweight tags
- **Clean tree required**: Refuse to tag with uncommitted changes (step 3)
- **Changelog first**: Always invoke `/changelog` before creating the tag (step 4)
- **Push after tagging**: Push the commit and the tag from the main conversation (step 7); never force push
- **No AI attribution**: Never add Co-Authored-By or AI references to the changelog commit
- **Bump argument required**: Reject invocation without `major`, `minor`, or `patch`
