docs: multi-location hubs + AGENTS.md/CLAUDE.md claims (and dogfood it)#133
Merged
Conversation
The hubs glob is a list, and any matched file that parses as a hub counts — including AGENTS.md/CLAUDE.md. Surface both possibilities so users can decide, rather than implying hubs must live in hubs/. configuration.md gains a multi-glob example (noting the union/dedup and the surf-new-uses-first-glob caveat). authoring-hubs.md gains a "Claims in AGENTS.md / CLAUDE.md" section presented as a deliberate trade-off, keeping the existing keep-them-separate default intact. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add AGENTS.md to the hubs glob and seal a single claim anchored to lint_agents_pointer — the lint rule that governs AGENTS.md itself. Writing a sealable claim surfaced that the existing prose overstated the rule (it enforces link+existence, not non-enumeration), so the prose is corrected to match the symbol. Logged in the dogfood-log. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documents two things Surface already supports but the docs didn't spell out — framed as possibilities users can choose, not prescriptions — then dogfoods one of them on this repo.
What changed
Docs
docs/reference/configuration.md— multi-globsurf.tomlexample; matches are unioned then sorted/de-duped (overlaps safe); any matching file that parses as a hub counts (incl.AGENTS.md); caveat thatsurf newuses only the first glob to scaffold.docs/guides/authoring-hubs.md— new "Claims inAGENTS.md/CLAUDE.md" section showing how those files can double as hubs, with the two gotchas (whole file must parse as a hub; it couples the file to code/CI). The keep-them-separate default is left intact; the fold-in is presented as a deliberate trade-off.Dogfood
surf.toml—hubs = ["hubs/*.md", "AGENTS.md"].AGENTS.md— now itself a hub: one sealed claim anchored tolint_agents_pointer(the lint rule that policesAGENTS.md). Writing the claim surfaced that the old prose overstated the rule (it enforces link + directory-existence, not non-enumeration), so the prose is corrected to match the symbol. Everything else stays plain, unanchored instruction.docs/dogfood-log.md— dated entry on how making the file sealable forced the prose honest.Verification
cargo fmt --all --check— passsurf lint— 0 errors (13 pre-existing advisory coverage warnings, unrelated)surf check— all anchored spans match their stored hashes🤖 Generated with Claude Code