setup / src
AGENTS.md0 starsChanged 5 days agoMITView on GitHub
This folder holds each git checkout on this Mac: each primary clone and each worktree. install.sh of the setup repo copies this file from src/AGENTS.md. Edit it there.
- Reads credentials
1 other project uses a version of this.
Adopted by
Most recently taken up by
- jpc4729/setupword for word, first seen Nov 1, 2026
Other versions1 project uses a version of this.
Word for word · 1
- jpc4729/setup★ 0100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 31,700 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository23 other files it gives its agents.
- AGENTS.mdAGENTS.md
- codex/AGENTS.mdAGENTS.md
- grok/AGENTS.mdAGENTS.md
- opencode/AGENTS.mdAGENTS.md
- claude/CLAUDE.mdCLAUDE.md
- context-doctorSkill
- diagnoseSkill
- handoffSkill
- intentSkill
- paper-useSkill
- retroSkill
- skills-claudeSkill
- ui-principlesSkill
- verify-setupSkill
- wayfinderSkill
- agent-browserSkill
- grillingSkill
- ponytail-auditSkill
- ponytail-debtSkill
- ponytail-reviewSkill
- ponytailSkill
- security-auditSkill
- thermo-nuclear-code-quality-reviewSkill
The file
We split this AGENTS.md into the rules it gives an agent
10 rules. About 0 are common, 4 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 24
Use <type>/<slug>, with one / only.
- Distinctive: line 27
Keep the branch name of a pull request from another person.
- Distinctive: line 28
Do not use a branch name again after its merge.
- Distinctive: line 45
Never switch the branch in a checkout: its folder name then is wrong.
- Very specific: line 46
Never delete or move a worktree folder by hand.
- Very specific: line 52
Remove a repo folder only when wt list shows no open work and git log --branches --not --remotes in the primary clone shows no commits.
- Distinctive: line 60
When the user asks for a new worktree, make it and give its work to a new session there.
- Very specific: line 61
Use the branch name that the user gives, or make one by the rules above.
- Very specific: line 62
Run wt switch -c <branch> --no-cd --format json, and take the path of the worktree from its output.
- Very specific: line 63
When this conversation has facts that the new session needs, such as the task, decisions or findings, write a handoff document as …
≈ “Common” is an estimate: at least 1 in 5 of the 40,246 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
~/.local/src
This folder holds each git checkout on this Mac: each primary clone and each worktree. install.sh of the setup repo copies this file from src/AGENTS.md. Edit it there.
Layout
~/.local/src/
AGENTS.md this file
local-src.code-workspace optional VS Code workspace, one folder per repo
<owner>/ GitHub user or org, as in the remote URL
<repo>/ repo name, as in the remote URL
main/ primary clone, always on the default branch
feat-oauth-refresh/ worktree of the branch feat/oauth-refresh- Each checkout is at
~/.local/src/<owner>/<repo>/<folder>, three levels down. Put nothing else at these levels. - The folder of a checkout is its branch name with each
/changed to-. The name always tells which branch is checked out in it. - The primary clone has the name of the default branch, usually
main, and stays on that branch. - Worktrunk (
wt) makes the worktree paths fromworktree-pathin~/.config/worktrunk/config.toml.
Branch names
- Use
<type>/<slug>, with one/only. Worktrunk changes/to-, sofeat/a-bandfeat-a/bwould get the same folder. <type>is a Conventional Commits type:feat,fix,refactor,perf,docs,test,build,ciorchore. Useexpfor work that you will not merge.<slug>is lowercase kebab-case (a-z,0-9,-), 2 to 5 words, at most 40 characters. Put the ticket key first when there is one:fix/eng-142-token-refresh.- Keep the branch name of a pull request from another person.
- Do not use a branch name again after its merge. Start new work on a new branch.
Commands
git clone https://github.com/<owner>/<repo>.git ~/.local/src/<owner>/<repo>/main # add a repo
wt switch -c feat/oauth-refresh # new branch and worktree, from the default branch
wt switch pr:123 # worktree of the branch of pull request 123
wt switch ^ # go to the primary clone
wt list # each worktree of this repo and its state
wt remove # remove this worktree, and its branch when merged
wt merge # squash into the local default branch, then remove the worktree
ls -d ~/.local/src/*/*/*/ # each checkout on this MacRules
- Never switch the branch in a checkout: its folder name then is wrong. Make a worktree for the other branch.
- Never delete or move a worktree folder by hand. Use
wt remove. When a folder is already gone, rungit worktree prunein the primary clone. - Each repo has an
originremote before its first worktree. Worktrunk takes<owner>and<repo>from it. - Untracked files, such as
.envandnode_modules, are separate in each worktree. Worktrunk copies them from the primary clone when it makes a worktree. - Worktrees of one repo can run at the same time. Give each dev server its own port, for example with
{{ branch | hash_port }}in the hooks of the repo's.config/wt.toml. - Each week, run
wt listin each repo you used and remove each merged worktree. - When you use
local-src.code-workspace, give it one folder per repo,<owner>/<repo>, named<repo>. VS Code shows each worktree in it and finds each checkout one level down as a Source Control repository. Add or remove a folder there only when you add or remove a repo. - Remove a repo folder only when
wt listshows no open work andgit log --branches --not --remotesin the primary clone shows no commits.
For agents
- You work in one checkout. Stay in it. A sibling folder is another branch of the same repo, and another agent can use it.
- Temp files go in the folder that
scratch <slug>prints,/tmp/agents/<owner>/<repo>/<slug>.XXXXXX, with the same<owner>/<repo>as here. - Make, move or remove a worktree, or switch the branch, only when the user asks. A switch makes the folder name wrong, so say so in your reply.
- To merge a pull request from a checkout, add
--repo <owner>/<repo>togh pr merge. Without it,--delete-branchswitches the checkout to the default branch and deletes the local branch. With it, gh deletes only the remote branch. Remove the worktree later withwt remove. - When the user asks for a new worktree, make it and give its work to a new session there. Do these steps, and do no work in the new worktree yourself:
- Use the branch name that the user gives, or make one by the rules above. Start from the default branch, unless the user names a base: add
--base <branch>, or--base @for the branch of this checkout. - Run
wt switch -c <branch> --no-cd --format json, and take the path of the worktree from its output. In a repo folder<owner>/<repo>/, which is not a checkout, add-Cwith a checkout in it. Never add-y: the user approves the hooks of a repo. - When this conversation has facts that the new session needs, such as the task, decisions or findings, write a handoff document as
~/.agents/skills/handoff/SKILL.mdtells. - Give the user one command that starts a session in the new worktree, then the kickoff prompt from that skill in one fenced block. For Claude Code, keep the account of this session:
cd <path> && claudewhenCLAUDE_CONFIG_DIRis not set, andcd <path> && CLAUDE_CONFIG_DIR=<its value> claudewhen it is set.
- Use the branch name that the user gives, or make one by the rules above. Start from the default branch, unless the user names a base: add
- Open as few pull requests as possible. Put all the work that the user gives you in this checkout on its branch, for one pull request: each item of a request, each follow-up, and each fix, feature, refactor, perf change or chore. Do not split work into more branches or pull requests by item, type, area or size, and do not suggest it.
- A branch can hold commits of different types. Its name takes the type of the main change.
- In the primary clone, give the user one branch name for all the work, with a name that follows the rules above. Suggest a second branch or pull request only when the user asks for it, or when the work is in another repo.
- For the code of a repo, its own
AGENTS.mdorCLAUDE.mdcomes before this file.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

