Skip to content

Commit b04d575

Browse files
hyperpolymathclaude
andcommitted
docs(governance): add Hypatia and gitbot-fleet standing rules to .claude/CLAUDE.md
Estate-wide governance rules for the Hypatia review bot and the gitbot-fleet auto-merge bot. Kept in a standalone section so the bots can read it cold without parsing the rest of CLAUDE.md. Four rules: - DOC-FORMAT: docs/ uses .adoc; .md only for community-health filenames. - DOC-DEDUP: block two open PRs from closing the same issue. - STACK-SIGNAL: docs PRs that document an unmerged feature must declare "Depends on: #NNN" and not auto-merge until the dep merges. - ISSUE-CLOSURE: bots never close issues directly; only via PR merge keywords or explicit human agreement. These rules are derived from the recurring failure modes seen in the PR #91 / #92 / #93 / #94 batch (duplicate codegen-env doc PRs both closing #89; affex-spec.md instead of .adoc; missing "Depends on: #92" on the docs PR for extern grammar). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 854f880 commit b04d575

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

.claude/CLAUDE.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,3 +99,32 @@ The 5 external references to `affinescript-deno-test/` (CI workflow, status docs
9999
- SHA-pinned dependencies
100100
- SPDX license headers on all files
101101

102+
## Hypatia and gitbot-fleet standing rules
103+
104+
Standing governance rules for the Hypatia review bot and the gitbot-fleet
105+
auto-merge bot. These are estate-wide policies; this section is the canonical
106+
copy that bots read at PR-review time. Keep this section standalone so it can
107+
be read cold without requiring the rest of CLAUDE.md as context.
108+
109+
### DOC-FORMAT
110+
Rule: All documentation files in docs/ must use .adoc extension.
111+
Exception: GitHub community-health files must use .md by name (CONTRIBUTING.md, CODE_OF_CONDUCT.md, SECURITY.md, CHANGELOG.md, README.md).
112+
Action (Hypatia): On any PR that adds or renames a docs/ file with .md extension (excluding the above exceptions), post a review comment requesting rename to .adoc and request-changes.
113+
Action (gitbot): Reject auto-merge for any PR with a docs/ .md file that is not a community-health file name.
114+
115+
### DOC-DEDUP
116+
Rule: Before creating a new docs/specs/*.adoc or adding a major new section to SPEC.adoc, search existing specs for overlapping coverage.
117+
Action (Hypatia): On any PR that closes the same issue number as another open PR, post a comment listing both PRs and ask the author to confirm which is canonical.
118+
Action (gitbot): Block merge if two open PRs share a "Closes #N" reference to the same issue.
119+
120+
### STACK-SIGNAL
121+
Rule: A docs PR that documents a feature implemented in a sibling feature PR must declare the dependency in its PR body.
122+
Format: Add a line "Depends on: #NNN" near the top of the PR body.
123+
Action (Hypatia): On any docs PR whose title or body references types/grammar/syntax added in an open feat PR, check whether "Depends on:" is present; if missing, request it.
124+
Action (gitbot): Do not auto-merge a PR with "Depends on: #NNN" until #NNN is merged.
125+
126+
### ISSUE-CLOSURE
127+
Rule: An issue is closed only by explicit merge of a PR with "Closes #N" OR by explicit human comment agreement in the issue thread. bots may not self-close issues.
128+
Action (Hypatia): When asked to close an issue, confirm via a reply on the issue thread before doing so.
129+
Action (gitbot): Never use GitHub's "close issue" API directly; only close via PR merge with "Closes #N" keywords.
130+

0 commit comments

Comments
 (0)