joelbrilliant/agentic-delivery-skills/dirty-worktree-discipline
Claude Code and agent skill by joelbrilliant/agentic-delivery-skills
- community
Checking that the SKILL.md file is still in the repository.
Keeps agent work safe in messy repositories. Use when git status is dirty, unrelated files exist, generated artefacts are present, multiple agents share a repo, or you must commit only the intended slice without damaging someone else's work.
Install
npx vskill@latest install joelbrilliant/agentic-delivery-skills/dirty-worktree-disciplineSKILL.md
The same SKILL.md was published earlier as joelbrilliant/agentic-delivery-skills/dirty-worktree-discipline.
Dirty Worktree Discipline
Overview
Use this skill before editing, staging, committing, or reverting in a repository that already has unrelated changes.
A dirty worktree is not an excuse to stop. It is a reason to be precise.
When to Use
git statusis not clean.- Generated files are present.
- Multiple agents or humans are working in the same repo.
- You need to commit only your slice.
- You are tempted to run broad cleanup or reset commands.
- A deploy or review requires exact source state.
Preflight
Capture:
Classify files:
- yours;
- pre-existing unrelated;
- generated artefacts;
- unknown and risky;
- ignored/cache/temp.
Rules
- Never run broad reset/clean by default. No
git reset --hard, nogit clean -fd, no mass restore without explicit scope. - Stage by path. Use
git add path1 path2, notgit add .. - Inspect staged diff. Run
git diff --cached --statandgit diff --cached --name-onlybefore commit. - Preserve unrelated work. Do not format, revert, or move files outside your slice.
- Generated artefacts need intent. If build output is required for deploy, say so. Otherwise leave it uncommitted.
- Dirty state is part of evidence. Report what remains dirty and why.
Commit Protocol
Before commit:
After commit:
Safe Commands
Good:
Risky, use only with explicit approval:
Anti-patterns
- "Workspace was messy so I committed everything."
- "I cleaned generated files and accidentally deleted someone else's artefacts."
- "I deployed from a dirty tree but did not report it."
- "I used broad restore because the diff was noisy."
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/dirty-worktree-discipline/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/joelbrilliant/agentic-delivery-skills/dirty-worktree-discipline)