Skip to content

Add agent guidance (AGENTS.md, CLAUDE.md, docs) and README fixes - #110

Open
mohlsen wants to merge 1 commit into
masterfrom
claude/silly-pike-10624f
Open

mohlsen wants to merge 1 commit into
masterfrom
claude/silly-pike-10624f

Conversation

@mohlsen

@mohlsen mohlsen commented Sep 29, 2026

Copy link
Copy Markdown
Owner

Summary

Sets the repo up so AI coding agents (Claude Code, Copilot, Codex, Cursor) can work on it safely. No changes to runtime code.

Agent guidance

  • AGENTS.md: the main guide for every agent. Covers commands, layout, code style, testing patterns, rules for agents, and open issues/PRs. Treats CLI output, exit codes and the result object as public API. Agents must never publish or version, and never bump colors past 1.4.0.
  • CLAUDE.md: imports AGENTS.md plus a few Claude-only notes.
  • .claude/skills/add-validator: the steps for adding a new tool. .claude/settings.json allows test, lint and read-only gh commands, and blocks npm publish / npm version.

Knowledge docs

  • docs/architecture.md: how data flows, the result object, exit codes, and how the test stubs work.
  • docs/known-issues.md: quirks confirmed by running the CLI, each marked as safe to fix or a breaking change. Examples: status is 0 even when the environment is invalid; engine keys with no validator fail the whole check; results come back in nondeterministic order; and a Bluebird → util.promisify swap would pass the tests but break real runs.
  • docs/adding-a-validator.md: recipe for adding a validator.

README fixes

  • The supported-tools table now shows the engines key and the command run. It adds the missing adb and windows rows and drops the stale semver column; all validators already support semver ranges.
  • The programmatic example had a syntax error and used status !== 0, which never catches an invalid environment. Both are fixed, and the result-object description is corrected.
  • Dev setup uses npm ci instead of installing ESLint globally.

Guardrails

  • lib/readme.spec.js: fails if a validator key has no row in the README table.
  • package.json files: the published package now contains only bin/ and lib/ runtime files (plus README/LICENSE/package.json). ⚠️ This changes what gets published: tests, lint config and the new docs no longer ship. Checked with npm pack --dry-run.
  • .gitignore: ignores .claude/worktrees/ and .claude/settings.local.json.

Test plan

  • npm test: 118 assertions pass (Node 24)
  • npm run lint: clean
  • Removed a README row on purpose and confirmed readme.spec.js fails with a clear message and a non-zero exit
  • npm pack --dry-run lists only runtime files

Related: builds on the context in draft #108 and #109 without overlapping their changes.

🤖 Generated with Claude Code

- AGENTS.md: shared guide for AI coding agents (commands, layout, conventions,
  testing patterns, boundaries, open work). CLAUDE.md imports it.
- docs/: architecture (data flow, result object, exit codes), verified known
  issues/tech debt, and an adding-a-validator recipe.
- .claude/: add-validator skill and shared permission settings.
- README: supported table now lists engine keys and commands (adds missing
  adb/windows, drops stale semver column); fix programmatic example and
  result-object description (status stays 0 on invalid environments).
- lib/readme.spec.js: fail if a validator is missing from the README table.
- package.json: add "files" so only bin/ and lib/ runtime files are published.
- .gitignore: ignore local-only Claude Code files.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
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