> ## Documentation Index
> Fetch the complete documentation index at: https://gump.top/sdlc-harness-docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Repository and governance commands

> Arguments, output, and exit status for init, adopt, validate, status, and traceability.

These commands install SDLC Harness, audit repository state, and read governance results. Except for `init` and `adopt`, they require the current directory to contain files generated by SDLC Harness.

<h2 id="init">
  `init`
</h2>

Generate the complete SDLC Harness protocol files in the current directory.

```bash theme={null}
npx @caesarlo/sdlc-harness init [--force]
```

| Argument | Type | Required | Default | Description |
| - | - | - | - | - |
| `--force` | boolean | No | `false` | Overwrite files that conflict with `init`. Without this option, any conflict stops the command before it writes any files. |

On success, `init` prints the number of files written and returns `0`. It exits nonzero for conflicts or write failures. Because `--force` overwrites existing content, review the conflict list before using it.

<h2 id="adopt">
  `adopt`
</h2>

Add SDLC Harness to an existing project while writing only missing files.

```bash theme={null}
npx @caesarlo/sdlc-harness adopt
```

This command has no arguments. Existing files remain unchanged. If the repository already has an `AGENTS.md`, Harness rules are written to `AGENTS.sdlc-harness.md`, which you must reference from the existing `AGENTS.md`.

<h2 id="validate">
  `validate`
</h2>

Run all repository governance audits.

```bash theme={null}
npx @caesarlo/sdlc-harness validate
```

This command has no arguments. When every audit passes, it prints `All checks passed.` and returns `0`. If any governance rule fails, it prints categorized errors and returns nonzero. `validate` audits repository records for compliance; it does not execute the verification commands declared by features.

<h2 id="status">
  `status`
</h2>

Output a JSON summary of current features, approvals, traceability gaps, and recommended next steps.

```bash theme={null}
npx @caesarlo/sdlc-harness status
```

This command has no arguments and does not modify the repository. See [Status and traceability output](/sdlc-harness-docs/reference/status-and-traceability-output#status) for field definitions.

<h2 id="traceability">
  `traceability`
</h2>

Build and output the complete traceability matrix.

```bash theme={null}
npx @caesarlo/sdlc-harness traceability
```

This command has no arguments and does not modify the repository. When the matrix applies, any actual gap makes the command return nonzero, including uncovered requirements, orphan stories or features, and uncovered or unverified acceptance criteria. It returns `0` when there are no actual gaps. See [Status and traceability output](/sdlc-harness-docs/reference/status-and-traceability-output#traceability) for field definitions.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.