Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ Chat*.txt
.claude/

# Local agent guidance — not shipped with the catalogue
CLAUDE.md

# Upstream inputs and build tooling — not shipped with any skill bundle
# (includes elixir-erlang/ — cloned Elixir/Erlang reference repos + a copyrighted
Expand Down
466 changes: 441 additions & 25 deletions AGENTS.md

Large diffs are not rendered by default.

14 changes: 14 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# CLAUDE.md

@AGENTS.md

> Record project knowledge in `AGENTS.md`, not here. This file holds only
> Claude-Code-only context (Standard §5.7).

## Claude Code specifics

- `microsoft-rust-guidelines` is `user-invocable: false` on purpose — it is the
mandatory auto-load Rust base and is hidden from the `/` menu by design. See
the editing rules in `AGENTS.md`; do not "fix" its absence from the menu.
- Skills reach Claude at `~/.claude/skills/<skill>`, one of the per-harness paths
Home Manager provisions (see "Local agent fan-out" in `AGENTS.md`).
5 changes: 3 additions & 2 deletions construct-cli/AGENTS.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# constructAI Coding-Agent Context
# AGENTS.mdconstruct

`construct` is the Spacecraft Software **Construct** skills package manager (Rust
CLI + TUI) — the first executable in the Construct catalogue repository. It
conforms to the Spacecraft Software Dual-Mode Self-Documenting CLI Standard
(v1.0.0). This file and `CLAUDE.md` are peers; keep them identical.
(v1.0.0). This is the authoritative agent context file (Standard §5.7); `CLAUDE.md`
imports it and adds only Claude-Code-only notes.

## Build / test / lint

Expand Down
6 changes: 6 additions & 0 deletions construct-cli/CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# CLAUDE.md

@AGENTS.md

> Record project knowledge in `AGENTS.md`, not here. This file holds only
> Claude-Code-only context (Standard §5.7).
13 changes: 11 additions & 2 deletions spacecraft-agentic-cli/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ repository root, on day one, before business logic:

| File | Primary consumer | Contents |
|------|------------------|----------|
| `AGENTS.md` | Generic agents (Codex CLI, Cursor, Aider, OpenCode) | Coding conventions, test/build commands, forbidden patterns, repository invariants |
| `CLAUDE.md` | Claude Code agent | Same as AGENTS.md, plus Claude Code–specific context (skills referenced, MCP servers expected, tool preferences) |
| `AGENTS.md` | **Every** agent (Codex CLI, Cursor, Aider, OpenCode, and Claude Code via the import) | **Authoritative.** Coding conventions, test/build commands, forbidden patterns, repository invariants |
| `CLAUDE.md` | Claude Code agent | An `@AGENTS.md` import plus Claude-only context (skills, `.claude/`, slash commands, MCP client) — never a restatement of AGENTS.md |
Comment on lines +85 to +86

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Rebuild the agentic CLI bundles

For users who install spacecraft-agentic-cli.zip or .skill, both unchanged bundles still contain the old guidance that CLAUDE.md should duplicate AGENTS.md; they also omit all four updated source/reference/template files in this commit. Rebuild and commit both bundles so the install surface actually delivers the policy introduced here.

AGENTS.md reference: AGENTS.md:L406-L409

Useful? React with 👍 / 👎.

| `SKILL.md` | Spacecraft Software Skills + CLI-Anything + `gws` | YAML frontmatter (name, description, license) + capability surface for the CLI itself |
| `CONTRIBUTING.md` | Human contributors | Onboarding, dev environment setup, PR conventions |

Expand All @@ -97,6 +97,15 @@ Drop-in templates live in `assets/agents-md.template.md` and
`assets/claude-md.template.md`. Never copy them blindly — each file must be
specialized for the project.

**Standard §5.7 is binding here.** `AGENTS.md` is the single source of
truth and every project must ship one; `CLAUDE.md` is an `@AGENTS.md`
import plus Claude-only content and must not restate it. Both are tracked
— a gitignored `AGENTS.md` makes the import dangle on a fresh clone — and
neither carries credentials, private hostnames, or personal filesystem
paths. Tooling that renders managed blocks into context files targets
`AGENTS.md` only. A "keep these two files in sync" instruction is not a
solution to drift; it is evidence the split is wrong.

**No-clobber: read before you write.** Scaffolding these files is the one
durable change this skill triggers on the user's own machine, and a repo often
already has an `AGENTS.md` or `CLAUDE.md` with real project context. **Read any
Expand Down
11 changes: 10 additions & 1 deletion spacecraft-agentic-cli/assets/agents-md.template.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,18 @@
# AGENTS.md — <PROJECT_NAME>

<!--
Spacecraft Software AGENTS.md template, version 1.0.0.
Spacecraft Software AGENTS.md template, version 2.0.0.
License: GPL-3.0-or-later

THIS FILE IS THE AUTHORITY (Standard §5.7). Every agent reads it —
Codex CLI, Cursor, Aider, OpenCode, Goose, and Claude Code (which
imports it from CLAUDE.md via `@AGENTS.md`). New project knowledge
goes HERE, not into a harness-specific file. CLAUDE.md holds only
what is meaningless to a non-Claude harness.

This file is tracked, never gitignored, and never carries credentials,
private hostnames, or personal filesystem paths.

Replace every <PLACEHOLDER> below with project-specific content.
Delete instruction comments before committing.

Expand Down
89 changes: 36 additions & 53 deletions spacecraft-agentic-cli/assets/claude-md.template.md
Original file line number Diff line number Diff line change
@@ -1,84 +1,67 @@
# CLAUDE.md — <PROJECT_NAME>

<!--
Spacecraft Software CLAUDE.md template, version 1.0.0.
Spacecraft Software CLAUDE.md template, version 2.0.0.
License: GPL-3.0-or-later

CLAUDE.md is a strict superset of AGENTS.md. Start by mirroring the
AGENTS.md content (either symlink or copy), then add the
Claude-specific sections at the bottom.
Standard §5.7 governs this file. AGENTS.md is the authority: it holds
every project fact — build commands, invariants, layout, forbidden
patterns. This file imports it and adds ONLY what a non-Claude harness
cannot act on.

Do NOT duplicate the CLI Standard here — those rules live in the
spacecraft-cli-standard and spacecraft-agentic-cli skills.
-->

<!-- ===== AGENTS.md content (mirror or symlink) ===== -->

## Project identity

<COPY-FROM-AGENTS.MD>

## Build, test, lint

<COPY-FROM-AGENTS.MD>

## Architectural invariants

<COPY-FROM-AGENTS.MD>
Do NOT copy, symlink, summarize, or mirror AGENTS.md here. If you find
yourself writing "keep these two files in sync," the split is wrong.

## Forbidden patterns

<COPY-FROM-AGENTS.MD>
Do NOT duplicate the CLI Standard here either — those rules live in the
spacecraft-cli-standard and spacecraft-agentic-cli skills.

## Environment expectations
CLAUDE.md is REQUIRED even when it holds nothing else. Claude Code reads
CLAUDE.md, not AGENTS.md — a project with only an AGENTS.md gives a
Claude session no project context at all. With nothing Claude-only to
say, the heading + @AGENTS.md + the blockquote is the whole file.

<COPY-FROM-AGENTS.MD>
Both AGENTS.md and CLAUDE.md are tracked. Neither may be gitignored, and
neither carries credentials, private hostnames, or personal filesystem
paths.
-->

## Where to look for ___
@AGENTS.md

<COPY-FROM-AGENTS.MD>
> Record project knowledge in `AGENTS.md`, not here. This file holds only
> Claude-Code-only context (skills, `.claude/`, slash commands, MCP client).

<!-- ===== Claude-specific additions ===== -->
<!-- ===== Claude-only content below this line ===== -->

## Skills referenced
## Skills to load

The following Spacecraft Software skills apply to this project. Claude should
consult them when their triggers match:
The following Spacecraft Software skills apply to this project. Consult them
via the Skill tool when their triggers match:

- `spacecraft-standard-constitution` — master Steelbore Standard
- `spacecraft-cli-standard` — structural CLI Standard rules
- `spacecraft-agentic-cli` — agent-facing UX for the CLI
- `spacecraft-brand-guidelines` — Steelbore 2 color palette (values from `steelbore-color-palette`)
- `spacecraft-brand-guidelines` — brand look-and-feel
- `steelbore-color-palette` — canonical palette values (§11)
- `microsoft-rust-guidelines` — Microsoft Pragmatic Rust Guidelines
- `spacecraft-cli-preference` — preferred external CLI tools (rg, fd, bat)
- `spacecraft-cli-shell` — shell syntax for generated commands
- <ADD-PROJECT-SPECIFIC-SKILLS>

## MCP servers expected

This project may coexist with the following MCP servers in agent
sessions:

- `<TOOL_NAME> mcp` — this project's own MCP surface (when implemented)
- <ADD-PROJECT-SPECIFIC-MCP-SERVERS>

## Tool preferences

- Use `rg` over `grep`, `fd` over `find`, `bat` over `cat` (per
spacecraft-cli-preference).
- Use `cargo nextest` over `cargo test` if available; fall back if not.
- Use `jaq` over `jq` for JSON filtering.
- <ADD-PROJECT-SPECIFIC-TOOL-PREFERENCES>
## Claude Code specifics

## Notes for Claude specifically

- Inline TODOs use `// TODO(claude):` to distinguish from human TODOs.
- Commit messages use the format `<type>(<scope>): <subject>` with
conventional-commits types.
- <Slash commands this repo installs, `.claude/` layout, plan-mode notes,
subagent conventions, TaskMaster wiring — anything meaningless to Codex,
Cursor, or Goose.>
- <ADD-PROJECT-SPECIFIC-CLAUDE-NOTES>

## Standards compliance

This project follows the Spacecraft Software Dual-Mode Self-Documenting CLI Standard (v1.0.0). The CLI Standard skills
are authoritative on structural and agentic conventions. This file
documents project-specific deviations and supplements only.
<!--
Tool preferences, commit-message format, and TODO conventions are NOT
Claude-only — they belong in AGENTS.md. Likewise CLAUDECODE=1 detection:
a CLI that checks it alongside CURSOR_AGENT and GEMINI_CLI is documenting
its own behavior, which every harness needs to know.
-->
49 changes: 43 additions & 6 deletions spacecraft-agentic-cli/references/agents-md-authoring.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ does NOT belong, and provides anti-pattern catalogs.

| File | Reader | Lifetime | Authoritative on |
|------|--------|----------|------------------|
| `AGENTS.md` | Generic agents (Codex CLI, Cursor, Aider, OpenCode, Goose) | Loaded each session | Coding conventions, build/test commands, project invariants |
| `CLAUDE.md` | Claude Code | Loaded each session | Same as AGENTS.md, plus Claude-specific tool/skill/MCP context |
| `AGENTS.md` | **Every** agent, Claude included (via the import below) | Loaded each session | **Authoritative.** Coding conventions, build/test commands, project invariants |
| `CLAUDE.md` | Claude Code | Loaded each session | An `@AGENTS.md` import plus Claude-only tool/skill/MCP context — nothing else |
| `SKILL.md` | Spacecraft Software Skills, CLI-Anything, `gws`-style skill systems | Loaded by skill loader | The CLI's own capability surface and triggering description |
| `CONTRIBUTING.md` | Human contributors | Read once during onboarding | Dev environment setup, PR conventions |

Expand Down Expand Up @@ -123,13 +123,29 @@ Cargo workspace. It targets POSIX shell environments first and PowerShell

## §3 — CLAUDE.md: how it differs from AGENTS.md

CLAUDE.md MUST be a strict superset of AGENTS.md. Start by symlinking or
copying AGENTS.md, then add Claude-specific sections:
**Standard §5.7 governs this file.** CLAUDE.md is an `@AGENTS.md` import
plus Claude-only content — it MUST NOT restate, summarize, or mirror
AGENTS.md. Copying or symlinking AGENTS.md into it is non-compliant: the
two copies are edited in different sessions, drift, and the agent reading
the stale one is never told it is stale.

> **This rule was inverted at Standard v1.46.** Earlier revisions of this
> reference told authors to make CLAUDE.md a strict superset by symlinking
> or copying. That produced duplication by construction. If you find a
> project still arranged that way, or a file carrying a "keep these two in
> sync" instruction, that instruction is the bug — fold the content into
> AGENTS.md and reduce CLAUDE.md to the shape below.

Anything that is true of the *project* goes in AGENTS.md. Only what a
non-Claude harness cannot act on belongs here:
Comment on lines +139 to +140

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Keep generic conventions out of the CLAUDE.md example

When authors follow this canonical example, the subsequent Tool preferences entries and the TODO(claude) source convention are placed only in CLAUDE.md, although Codex and other harnesses also need those project-wide rules. Remove those generic entries from the overlay example or move them into its AGENTS.md example so the reference does not contradict the new single-source rule.

AGENTS.md reference: AGENTS.md:L434-L436

Useful? React with 👍 / 👎.


```markdown
# CLAUDE.md — <project-name>

<!-- All AGENTS.md content above -->
@AGENTS.md

> Record project knowledge in `AGENTS.md`, not here. This file holds
> only Claude-Code-only context.

## Skills referenced
- `spacecraft-standard-constitution` — master Standard
Expand Down Expand Up @@ -158,6 +174,27 @@ The Claude-specific sections matter because Claude Code has features
Mentioning them in AGENTS.md would mislead a Codex CLI session into
expecting capabilities it doesn't have.

**The test for where a fact belongs:** would a Codex CLI or Cursor session
be worse off without it? If yes, it goes in AGENTS.md. `CLAUDECODE=1` is
the classic false positive — a CLI that detects it alongside `CURSOR_AGENT`
and `GEMINI_CLI` is documenting its own product behavior, which every
harness needs to know, so it belongs in AGENTS.md.

**CLAUDE.md is mandatory, even when it holds nothing else.** Claude Code
reads `CLAUDE.md`, not `AGENTS.md` — a project with only an AGENTS.md
gives a Claude session *no* project context at all. When there is nothing
Claude-only to say, the file is still four lines: the heading, the
`@AGENTS.md` import, and the blockquote.

Both files are tracked (§5.7). Neither may be gitignored: an ignored
AGENTS.md makes the import dangle on a fresh clone. Because they are
published artifacts, keep credentials, private hostnames, and personal
filesystem paths out of both — and review a previously-ignored context
file for sensitive content *before* un-ignoring it.

Tooling that renders managed blocks into context files (rule
synchronizers, task systems) targets AGENTS.md only.

---

## §4 — SKILL.md: the CLI's own skill manifest
Expand Down Expand Up @@ -295,7 +332,7 @@ are inline in `#[cfg(test)] mod tests {}` blocks."
| File | Target length | Hard cap |
|------|---------------|----------|
| AGENTS.md | 80–200 lines | 400 lines |
| CLAUDE.md | 100–250 lines | 500 lines |
| CLAUDE.md | 5–40 lines | 80 lines |
| SKILL.md | 50–150 lines | 300 lines |
| CONTRIBUTING.md | (no agent-loaded budget) | — |

Expand Down
Loading
Loading