git-ops
Automates Git tasks with strict commit message standards and clear branching history.
Install
mkdir -p .claude/skills/git-ops && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/10465" && unzip -o skill.zip -d .claude/skills/git-ops && rm skill.zipInstalls to .claude/skills/git-ops
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Git operations with enforced conventions: branch from issues, conventional commits, clean history, tagging releases. Use when: starting work on a new feature or bug fix (create branch), committing completed work, creating a release tag, cleaning up branches, or enforcing commit message standards. Does NOT push or force-push without confirmation.Key capabilities
- →Create branches
- →Commit changes
- →Tag releases
- →Clean up branches
How it works
It enforces conventional commit formats and branch naming conventions to maintain a clean and communicative git history.
Inputs & outputs
When to use git-ops
- →Branching for a feature
- →Committing work
- →Tagging a release
- →Cleaning up git history
About this skill
Git Ops — Branch, Commit, Tag
Git history is a permanent record. Every commit message, every branch name, every tag communicates intent to future developers (including you in 6 months). Do it right the first time.
When to Use
- Starting work on a new feature or bug (create a branch)
- Completing work and committing
- Creating a release
- Cleaning up merged branches
- Reviewing what changed before committing
Branch Naming Convention
feature/<issue-number>-<short-slug> # new features
fix/<issue-number>-<short-slug> # bug fixes
chore/<short-slug> # maintenance, deps, config
docs/<short-slug> # documentation only
refactor/<short-slug> # refactors (no behavior change)
Examples:
feature/42-user-authenticationfix/17-login-redirect-loopchore/update-dependencies
Always branch from main unless directed otherwise:
git checkout main
git pull origin main
git checkout -b feature/<issue-number>-<slug>
Conventional Commits
Every commit must follow this format:
<type>(<scope>): <short description>
[optional body — what and why, not how]
[optional footer: Closes #N, Breaking-Change: ...]
Types
| Type | When |
|---|---|
feat | New feature |
fix | Bug fix |
chore | Build, deps, config (no production code) |
docs | Documentation only |
refactor | Code change without behavior change |
test | Adding or fixing tests |
perf | Performance improvement |
ci | CI/CD changes |
Scope
Optional but encouraged — the module or area affected:
feat(auth): add JWT refresh token supportfix(api): handle null response from user endpoint
Rules for the Subject Line
- Lowercase, no period at the end
- Imperative mood: "add feature" not "added feature" or "adds feature"
- Max 72 characters
- Be specific: "fix login redirect loop on token expiry" not "fix bug"
Commit Procedure
Step 1 — Review what you're committing
git status
git diff --staged
Never commit without reviewing the diff. git add . followed by a blind commit is how secrets and debug code get into repos.
Step 2 — Stage intentionally
# Stage specific files (preferred)
git add src/auth/handler.ts tests/auth.test.ts
# Stage all tracked changes (only after reviewing git status)
git add -u
# Never use git add . without reviewing — it picks up everything including temp files
Step 3 — Commit with a conventional message
git commit -m "feat(auth): add JWT refresh token rotation"
# or with body
git commit -m "fix(api): handle null user response
The /users endpoint can return null for deactivated accounts.
Previously this caused an unhandled exception in the serializer.
Closes #34"
Step 4 — Verify the commit
git log --oneline -3
Confirm the message and files look right.
Tagging Releases
Use semantic versioning: MAJOR.MINOR.PATCH
MAJOR: breaking changeMINOR: new feature, backward compatiblePATCH: bug fix, backward compatible
# Annotated tag (required for releases — not lightweight tags)
git tag -a v1.2.0 -m "Release v1.2.0 — adds JWT refresh token rotation"
# List tags
git tag -l
After tagging, push to remote:
git push origin main
git push origin v1.2.0
Confirm with the user before pushing. Pushing is not reversible without a force-push.
Pre-Commit Checklist
Before every commit, verify:
-
get_errors()returns zero errors - Lint passes:
npx eslint src --max-warnings 0 - Type-check passes:
npx tsc --noEmit - Tests pass:
npm test -
git diff --stagedreviewed — no debug code, no secrets, no.envfiles - Commit message follows conventional commits format
-
TODO.mdupdated to reflect completed items
Branch Cleanup
After a PR is merged:
git checkout main
git pull origin main
git branch -d feature/<slug> # local cleanup
Remote branch cleanup is handled by GitHub's "auto-delete head branches" setting (enable this in repo settings).
Rules
- Never commit directly to
main— always use a branch + PR - Never commit secrets, API keys, or
.envfiles — check.gitignorebefore staging - Never use
--forcewithout explicit user confirmation — force-push rewrites history for everyone - One logical change per commit — don't bundle unrelated changes
- Commit early, commit often — small commits are easier to revert and review
- If
git statusshows files you don't recognize, investigate before staging anything
When not to use it
- →Force-pushing
- →Committing secrets
Prerequisites
Limitations
- →Requires user confirmation for pushing
- →No force-pushing
How it compares
It mandates a pre-commit checklist including linting and type-checking, ensuring only high-quality code enters the history.
Compared to similar skills
git-ops side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| git-ops (this skill) | 0 | 2mo | Review | Beginner |
| tmux | 20 | 2mo | Review | Intermediate |
| jira | 11 | 6mo | No flags | Beginner |
| triaging-issues | 5 | 2mo | Review | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
tmux
openclaw
Remote-control tmux sessions for interactive CLIs by sending keystrokes and scraping pane output.
jira
davila7
Use when the user mentions Jira issues (e.g., "PROJ-123"), asks about tickets, wants to create/view/update issues, check sprint status, or manage their Jira workflow. Triggers on keywords like "jira", "issue", "ticket", "sprint", "backlog", or issue key patterns.
triaging-issues
pytorch
Triages GitHub issues by routing to oncall teams, applying labels, and closing questions. Use when processing new PyTorch issues or when asked to triage an issue.
file-manager
Xxiii8322766509
文件管理技能。用于创建、移动、复制、删除文件和文件夹,整理目录结构。当用户需要管理文件、整理文件夹或批量处理文件时使用。
openspec-archive-change
studyzy
归档实验性工作流中已完成的变更。当用户想要在实现完成后最终确定并归档变更时使用。
slash-commands
parcadei
Create and use Claude Code slash commands - quick prompts, bash execution, file references