Skip to content

docs(claude+skills): CLAUDE.md restructure + path-guard + new skills#1301

Merged
John-David Dalton (jdalton) merged 2 commits intomainfrom
chore/split-skills-claudemd
May 5, 2026
Merged

docs(claude+skills): CLAUDE.md restructure + path-guard + new skills#1301
John-David Dalton (jdalton) merged 2 commits intomainfrom
chore/split-skills-claudemd

Conversation

@jdalton
Copy link
Copy Markdown
Collaborator

@jdalton John-David Dalton (jdalton) commented May 5, 2026

Summary

  • CLAUDE.md restructure — fleet-canonical layout (public-surface
    hygiene, parallel-session safeguards, code style, tooling rules)
    with project-specific extensions below.
  • New skillspath-guard, programmatic-claude-lockdown,
    promise-race-pitfall.
  • Skills updatedsecurity-scan (AgentShield + zizmor + Socket
    CLI dependency scanning, A–F graded report).
  • Path-guard infrascripts/check-paths.mts,
    .github/paths-allowlist.yml, skill reference templates.
  • Doctrine referencesdocs/references/inclusive-language.md,
    docs/references/sorting.md.
  • Repo-template integration.socket-repo-template.json +
    schema tooling.

Scope

This is the skills + CLAUDE.md slice split out of #1286. Companion
splits:

After all three splits are reviewed, #1286 closes.

Test plan


Note

Medium Risk
Medium risk because it introduces a new repo-wide check-paths gate script and associated allowlist/templates that could later be wired into CI/pnpm check and start blocking merges if detection heuristics are too strict or noisy.

Overview
Adds path hygiene enforcement infrastructure: a new scripts/check-paths.mts gate (with allowlisting via .github/paths-allowlist.yml) plus the /path-guard skill and shared rule text, to enforce the “1 path, 1 reference” policy across TS, workflows, and build scripts.

Restructures CLAUDE.md into a fleet-canonical section and adds new guidance references/skills (programmatic Claude invocation lockdown, Promise.race pitfall) and minor security-scan/security-reviewer documentation tweaks (e.g., zizmor markers, soak-window checklist wording).

Introduces socket-repo-template integration artifacts (.socket-repo-template.json plus schema source/emit script and generated socket-repo-template-schema.json) and adds doctrine reference docs for inclusive language and sorting.

Reviewed by Cursor Bugbot for commit 101f571. Configure here.

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is ON. A cloud agent has been kicked off to fix the reported issue.

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 101f571. Configure here.

Comment thread scripts/check-paths.mts
Synced from socket-repo-template canonical. The fleet CLAUDE.md
moved to a fleet-canonical / project-specific layout — public-surface
hygiene rules, parallel-session safeguards, code style, and tooling
go in CLAUDE.md; project-specific extensions (build commands, test
targets, repo-particular conventions) go below.

Skills added:
- path-guard — audit and fix path duplication ("1 path, 1 reference")
- programmatic-claude-lockdown — reference for locking down headless
  Claude invocations (claude CLI in workflows, agent-sdk query() in
  code) per the four-flag lockdown pattern
- promise-race-pitfall — reference for the Promise.race
  cross-iteration handler-leak bug

Skills updated:
- security-scan — wires AgentShield + zizmor + Socket CLI dependency
  scanning, A-F graded report

Path-guard infra:
- scripts/check-paths.mts — repo-level path-duplication scanner
- .github/paths-allowlist.yml — known-acceptable duplicates
- .claude/skills/path-guard/reference/* — templates for new repos

Doctrine references:
- docs/references/inclusive-language.md — substitution table
- docs/references/sorting.md — alphanumeric sort rules

Repo-template integration:
- .socket-repo-template.json — repo-particular kind config
- scripts/socket-repo-template-{schema,emit-schema}.mts — schema tooling
- socket-repo-template-schema.json — emitted JSON schema

Splits content out of #1286. Companion split PR #1300 covers hooks +
harness config; deps_misc bucket folds into #1285 SHA cascade per
project direction.
Cursor Bugbot caught: `checkRuleF` grouped Rule-A findings purely by
string-literal shape and promoted to Rule F whenever count >= 2,
without checking distinct files. Two hand-builds of the same path
shape in the SAME file would be incorrectly flagged as 'cross-file
repetition' — but Rule F's whole point is cross-file duplication.

Fix: build a Set of distinct file paths and gate the promotion on
size >= 2. Also include the file count in the message
(`in N files (M places)`) so the reviewer knows both numbers.
Synced to socket-repo-template canonical.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant