Commit Commands
148,649 starsOfficial Anthropic plugin for Claude Code: three slash commands streamlining git workflow — /commit analyzes staged and unstaged changes, matches the repo's commit style and creates the commit; /commit-push-pr commits, pushes and opens a Pull Request in one step; /clean_gone removes local branches marked [gone] (deleted on the remote) along with their worktrees.
- First published:2025-10-08
- data as of:
- 2026-09-30
Host
Performs git operations in your repository: reads status and diffs, stages files, creates commits (/commit); /commit-push-pr additionally pushes to the remote and opens a PR — externally visible actions; /clean_gone deletes local branches and worktrees. The commands drive Claude to run git, with exactly the shell permissions you granted Claude Code.
It is packaged in Claude Code's plugin format: a .claude-plugin/plugin.json manifest plus slash-command Markdown files under commands/, parsed and injected into sessions by Claude Code's command loader. OpenClaw, Hermes Agent and DeepSeek Harness each use different extension mechanisms (npm plugin packages, catalog-pinned plugins, Cordis bundles) and will not load this format.
Risk
Auto-generated commits may stage files that should never land (keys, .env, debug code); /commit-push-pr upgrades a commit into a publication — one mistake goes straight into remote history and PR discussion; /clean_gone deletes branches along with any unmerged work on them. An injected agent can also use these commands to launder malicious changes into the repo quickly.
Install prompt
在 Claude Code 的插件管理介面中,從官方 marketplace(claude-plugins-official,Claude Code 預設已內建啟用)安裝 commit-commands;安裝後 /commit、/commit-push-pr、/clean_gone 即可在會話中使用。插件原始碼與說明見 anthropics/claude-code 倉庫的 plugins/commit-commands 目錄。Paste this to your agent. It deliberately contains no tool subcommands — check the tool's official docs for commands.