issue-tracker.md becomes Conventions (operations as Gitea concepts) and a Tool section with one tea command per operation, tea api for blocked_by dependencies. It names no skill or MCP tool, and drops the maintainer-only token and account-lookup lines. setup.md adds The tracker: install tea 0.14.2 or later and log in with a token of your own account. dev-setup.sh warns when tea is missing or older; it installs nothing. Closes #267 Assisted-by: Claude Code
4.3 KiB
4.3 KiB
Setup
Read this before setting up a clone, or an agent tool, to work on this repository.
Every rule below gives its reason and how it is held: by a control (a named hook or check), by review, or aspirational (checked by nothing and nobody). Links between the contributor docs are held by review until an offline link check exists.
The clone
- Run
scripts/dev-setup.shonce per clone, and again after a change torequirements-dev.txt, its lockrequirements-dev.lock,requirements.ymlor the hook types. It creates.venvwith the pinned tools on the Python named in.python-version, installs the collections ofrequirements.ymlinto.ansible/collections, and installs the git hooks (pre-commit, commit-msg, pre-push) with the virtualenv first on theirPATH. Reason: several hooks run their tools by name (language: system), so they fail without that virtualenv, and local lint must resolve the collection versions CI does. Held by: aspirational (a hook run without the virtualenv fails, which shows the step was skipped). - Run
pre-commit run --all-filesbefore pushing. Reason: a finding then stops you before the push instead of failing CI after it. Held by: control: the Lint check runs the same hooks on every pull request. - Let
git pushrunansible-test sanityon HEAD (scripts/ansible-test-sanity.sh, the Build check's sanity test); its first run builds virtualenvs and takes minutes. Reason: a finding only that test reports stops the push instead of the Build check. Held by: control: the pre-push hook, and the Build check.
The tracker
- Install
tea0.14.2 or later, by any of its official routes: Homebrew (brew install tea), your distribution's package, or a release binary from https://gitea.com/gitea/tea/releases checked against that release'schecksums.txt, whosechecksums.txt.sigis signed by the Gitea release key (7C9E68152594688862D62AF62D9AE806EC1592E2). Reason: it is the client issue-tracker.md gives commands for, and those commands assume 0.14.2 or later. Held by: aspirational (scripts/dev-setup.shwarns whenteais missing or older). - Log in with a token of your own account, with the scopes
write:issueandread:useronly:tea login add --url https://git.rkdr.net --token '<your-token>'. Create the token under Settings > Applications on the forge.tea login addneedsread:user; thatwrite:issuecovers every command of the Tool section is checked in issue #360. Reason: what you or your agent do on the tracker is then yours, and a token that leaks can do no more than edit issues. Held by: aspirational.
Agent tools
- Use Claude Code 2.1.281 or later.
Reason: older versions read no
AGENTS.md, or onlyCLAUDE.mdin some sessions, so the agent works without this repository's guidance. Held by: aspirational. - Keep personal notes in
~/.claude/CLAUDE.md. Never createCLAUDE.local.mdor aCLAUDE.mdin the clone, and keep noCLAUDE.mdin any directory above the clone. Reason: Claude Code reads aCLAUDE.mdit finds there instead of theAGENTS.mdfiles, so the agent loses this repository's guidance. Held by: review for a committed file, until a hook refuses one (issue #244); aspirational for files outside the repository. - Confirm that Claude Code's startup line reads
no CLAUDE.md found; AGENTS.md loaded: .... Reason: it is the one visible sign that the agent loaded the guidance. Held by: aspirational. - The tracked
.claude/settings.jsonnever holdspermissions.allow;denyandaskrules are allowed. Your own allowlist, hooks and any other rules you do not want shared go in.claude/settings.local.json, which is never committed. Reason: a branch's settings take effect for whoever opens it with an agent, so anallowrule pushed on an unmerged branch lets that branch's commands run without a prompt before anyone has reviewed it, while adenyoraskrule can only add prompts. Held by: review (.claude/is underCODEOWNERS). - Every hook in the tracked
.claude/settings.jsonarrives through apm; personal hooks go in.claude/settings.local.json. Reason: a hook nobody owns is checked by nothing. Held by: review (.claude/is underCODEOWNERS).