release

A command for carrying out a software release using a patch, minor, or major version change. It checks the repository state, updates the version, and continues through the release process described by the workflow.

In plain words
What is it for?
Use it to prepare patch releases for fixes, minor releases for backward-compatible additions, or major releases for breaking changes in the Code Insights CLI.
Why use it?
It provides a defined sequence of checks before publishing, such as being on the master branch, having no uncommitted changes, and pulling the latest code.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/melagiri/code-insights/release
Clone the repo
git clone --depth 1 https://github.com/melagiri/code-insights

Made for: Claude Code.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,713 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01713
Opus 5 $0.00000 $0.00856
Sonnet 5 $0.00000 $0.00343
Haiku 4.5 $0.00000 $0.00171

Measured 2d ago against content hash 2aad6d941324, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

release scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/release.md · 244 lines

How it starts

The opening of the file, as written. The whole thing — 244 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/release — Automated Release Workflow

Arguments: $ARGUMENTS

You are executing the release workflow for @code-insights/cli. Parse $ARGUMENTS to extract:

  • type (required): patch, minor, or major
  • description (optional): A one-liner for the release title

If type is missing or not one of patch/minor/major, ask the user to provide it.


Step 1: Pre-flight Checks

Run ALL of these checks. If any fail, STOP and tell the user what to fix.

# Must be on master
git branch --show-current  # Must output "master"

# Must have clean working tree
git status --porcelain     # Must be empty

# Pull latest
git pull origin master

Read the current version from cli/package.json (the "version" field).

Compute the new version:

  • patch: increment the third number (3.6.1 → 3.6.2)
  • minor: increment the second number, reset third to 0 (3.6.1 → 3.7.0)
  • major: increment the first number, reset second and third to 0 (3.6.1 → 4.0.0)

Resume detection: Run npm view @code-insights/cli version to get the currently published version. If the version in package.json is ALREADY GREATER than the npm version, this is a resumed release — skip to Step 6.


Step 2: Analyze Changes

Find the last git tag and analyze what changed:

# Find latest tag
git describe --tags --abbrev=0

# Commits since last tag
git log $(git describe --tags --abbrev=0)..HEAD --oneline

# Full diff since last tag
git diff $(git describe --tags --abbrev=0)..HEAD --stat

Read the full diff and commit messages. Then:

  1. Generate a CHANGELOG entry in the existing format (see cli/CHANGELOG.md for style). Group changes under ### Added, ### Changed, ### Fixed, ### Improved as appropriate. Match the existing tone — concise but descriptive, with bold lead-ins.

  2. Generate a release title — a short phrase summarizing the release (e.g., "LLM-Powered Export Page", "PostHog custom domain"). Use the user's description if provided, otherwise derive from the changes.

Read the full file on GitHub · 244 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 244 lines · 0 tokens per session scan A 2aad6d941324

Subscribe to this mod's changes

release is a command published in the GitHub repository melagiri/code-insights (76 stars, last pushed 3mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,713 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.