A repository-local skill for setting up and running guarded Git releases. It supports single-package JavaScript/React projects and independently versioned monorepo targets.
The skill updates JSON package versions, creates target-prefixed annotated SemVer tags, and atomically pushes the release branch and tags. Existing CI/CD remains responsible for the actual deployment.
This fits pipelines where a change already passed earlier test stages before a release is finalized, for example:
Dev tests -> Main tests -> version finalized -> git-safe-release
Run it only at that last step, once the release branch already reflects a change confirmed
ready to ship. The skill does not run Dev or Main tests and does not manage promotion
between those branches; each target's verifyCommands is a final build check before
tagging, not a substitute for that CI. If you also configure integrationBranch (for
example your Dev branch), the skill compares it with the release branch on every run and
asks you to confirm whether an intentional hotfix bypassed the normal Dev -> Main flow —
useful when a release-branch commit has no matching Dev history to trace back to.
- Git with a remote that supports atomic pushes
- Node.js 18 or newer for the skill scripts
- Bash for rehearsal and self-tests
rsync,cp, or PowerShell for installation- A tool that reads project-local Claude or Agent skills
- macOS, Linux, or Windows; use Git Bash or WSL for Bash-based commands on Windows
The included fixture apps require Node.js 22.13 or newer and pnpm 11.1.2.
Copy both hidden directories into the project root.
macOS or Linux:
rsync -a .claude .agents /path/to/project/Windows PowerShell:
Copy-Item -Recurse -Force .claude, .agents -Destination C:\path\to\projectThe canonical skill lives at .claude/skills/git-safe-release.
.agents/skills/git-safe-release is a small compatibility wrapper that tells
Agent-skill hosts to load the canonical skill. It is a normal directory rather than a
symlink, so standard Windows ZIP, extraction, clone, and copy operations preserve it.
Ask the agent:
Use $git-safe-release to set up releases for this repository.
Setup inspects package manifests, branches, existing tags, and deployment workflows. It then asks for confirmation before generating:
.claude/skills/git-safe-release/project.config.json
By default, a target named storefront uses tags such as
storefront_v1.0.0 while its package version remains 1.0.0.
Use $git-safe-release to release the affected app with a patch bump.
The skill validates repository state, remote tags, branch relationships, target impact, and the exact release plan before modifying or pushing anything. It never force-pushes, moves tags, or silently merges branches.
Use $git-safe-release to rehearse a release for storefront.
Rehearsal creates an isolated local bare remote under /tmp. It cannot trigger GitHub
Actions or reach Production.
Two minimal projects exercise setup discovery and configuration validation:
fixtures/single-react: one Vite + React app with a rootpackage.jsonfixtures/pnpm-turbo: a pnpm workspace with Turborepo, two independently versioned React apps, and one shared UI package
Fixture workflows only print a message and never deploy. Run all fixture and isolated release checks with:
bash .claude/skills/git-safe-release/scripts/self-test.shThe fixtures are repository test data. Installing the skill still copies only .claude
and .agents.
The repository's own GitHub Actions workflow runs the skill self-test and installs and builds both fixtures for every push and pull request. It has read-only repository permission, uses no deployment secrets, and never releases or deploys a fixture.
For a manual agent-level acceptance test, copy the skill into a clean fixture repository,
start a fresh agent session, ask it to run setup, compare the generated
project.config.json with expected-project.config.json, and then request a rehearsal.
- JSON files with a top-level plain
x.y.zversion - one or more independently versioned targets
- configurable
<app>_v<version>tag prefixes - branch-push, tag-push, manual, or release-only deployment policies
- optional integration-branch hotfix detection
- Git remotes that support atomic pushes
The skill does not create CI/CD workflows or deploy directly to a cloud provider.