witt3rd/dotagent/git
Claude Code and agent skill by witt3rd/dotagent
- community
Checking that the SKILL.md file is still in the repository.
House git discipline — applies to ALL repos. Two modes: work on main during active debugging/iteration (commit frequently), or use worktrees for parallel feature work. Never accumulate uncommitted work. Always sync with origin/main before starting. Covers repo hygiene and the clean end-state: no stale worktrees, no local branches beyond the mainline, mainline at tip of origin, primary clone clean.
Install
npx vskill@latest install witt3rd/dotagent/gitSKILL.md
House git discipline (all repos)
Two modes, one rule
Mode 1: Active debugging/iteration — work on main. Commit small batches frequently. Push to a branch when stable. The git history is a breadcrumb trail.
Mode 2: Parallel feature work — use worktrees. Different agents building different features that don't touch the same files. If they do touch the same files, coordinate: one agent works at a time on that file.
The rule: never accumulate uncommitted work. Commit every 30 minutes during debugging. Small, revertable commits. "Fix X" not "down to one last bug?"
Active debugging workflow
Parallel feature workflow (worktrees)
Use worktrees when two agents are building distinct features that don't touch the same files. If they do touch the same files, coordinate — one agent works at a time on that file.
The two commands
Scripts live at ~/.local/bin/git-wt-new and ~/.local/bin/git-wt-rm.
Conventions
- Branch
docs/<x>/fix/<x>/feat/<x>/task/<x>→ folderdocs--<x>(kebab-case,
/ → --). Match the repo's existing branch shape (git branch -a) when unsure.
- Before opening a PR, sync with origin/main — always
git pull origin mainfirst,
rebase if needed, then push.
- Commit messages: imperative mood, ≤72 chars. "fix: ..." / "feat: ..." / "chore: ..."
Before starting any session
Always start from the latest origin/main. Never start from a stale state.
Never accumulate uncommitted work
- Commit every 30 minutes during debugging
- Small, revertable commits: "fix smoke test", "add debug logging", "revert that"
- The git history is a breadcrumb trail, not a pristine record
- If you need to roll back,
git revert <commit>— don't lose work
State and repair
git worktree list— see every worktree and its branch.- If a worktree got moved out-of-band with a plain
mv, git's registration still points at
the old path (listed prunable). Repair from inside the moved worktree: git worktree repair then git worktree prune.
Repo hygiene — the clean end-state (a contract, not a nicety)
"Clean" is a checkable end-state, not a feeling. A repo is clean — ready for the next agent to pick up cold — when ALL of these hold:
- No stale worktrees. Every worktree under
<repo>.wt/belongs to a branch whose work
is still in flight. Once merged, remove it: git wt-rm.
- No local branches beyond the mainline.
git branchshows only the mainline plus any
branch with a live worktree.
- The mainline is at the tip of origin (or deliberately ahead/behind and recorded).
git status -sb on the mainline should read ## main...origin/main with no ahead/behind — unless a push/PR is intentionally deferred.
- The primary clone is clean. No uncommitted work. All work committed.
Integrity sweep
Run these checks IN ORDER. Fix what fails, then move on.
- Unpushed commits (
git status -sb,git log --oneline origin/main..HEAD) - Uncommitted work (
git status --porcelain) - Local branches — merged or abandoned? (
git branch --merged origin/main) - Stale worktrees (
git worktree list) - The mainline is at origin tip (
git fetch origin && git status -sb)
The handoff channel
agent handoff <subject> — an event in .agent/log/. .agent/HANDOFF.md is retired and taboo (agent check fails if it exists). No ledger? inhabit first.
As an agent
- During debugging: work on main, commit frequently, push when stable.
- For parallel features: use worktrees. Different agents, different files.
- Before any session:
git pull origin main. - Before any PR: sync with origin/main, rebase if needed.
- Read each repo's AGENTS.md for repo-specific rules.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/git/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/witt3rd/dotagent/git)