Skip to content

Latest commit

 

History

History
173 lines (117 loc) · 4.94 KB

File metadata and controls

173 lines (117 loc) · 4.94 KB
title CLI Reference
description Commands around the portable fingerprint lifecycle. Your agent handles the judgment work.
kicker Docs
section guide
order 30
slug cli

The CLI does the repeatable parts around the fingerprint lifecycle: capture packages, report readiness, validate files, gather optional source material, emit handoff packets, govern diffs, compare packages, and record intent. Your agent does the reading, writing, and reviewing.

ghost --help intentionally shows the short core workflow for new adopters. Run ghost --help --all for the complete advanced and legacy command index; command-specific help remains available with ghost <command> --help.

Canonical Ghost fingerprints start here, with optional child packages for scoped product areas:

.ghost/fingerprint/manifest.yml
.ghost/fingerprint/prose.yml
.ghost/fingerprint/inventory.yml
.ghost/fingerprint/composition.yml
.ghost/fingerprint/enforcement/checks.yml
apps/checkout/.ghost/fingerprint/manifest.yml

The tables below are generated from the CLI source. Run pnpm dump:cli-help after command or flag changes.

Initialize - init

Create a .ghost/fingerprint/ package with a manifest, raw core layer files, and enforcement checks. Use --scope <path> for nested package roots. Use --memory-dir <relative-dir> when a host adapter stores Ghost package roots under a different safe relative directory.

ghost init
ghost init --with-intent
ghost init --scope apps/checkout --with-intent
ghost init --scope apps/checkout --memory-dir .design/memory

Layer readiness - scan

Report whether fingerprint/manifest.yml is present and which useful layers it has: prose, inventory, and composition. Generated cache does not count toward inventory readiness.

ghost scan
ghost scan --format json
ghost scan --include-nested --memory-dir .design/memory --format json

Stack inspection - stack

Inspect the root-to-leaf fingerprint stack for one or more paths.

ghost stack apps/checkout/review/page.tsx --format json

Capture source material - inventory

Emit raw signals about a frontend repo as JSON. Use this as optional source material under .ghost/fingerprint/sources/cache/.

mkdir -p .ghost/fingerprint/sources/cache
ghost inventory > .ghost/fingerprint/sources/cache/inventory.json

Validation - lint

Validate a root .ghost fingerprint package or an individual split artifact. --all validates every nested package and merged stack.

ghost lint
ghost lint .ghost/fingerprint/prose.yml
ghost lint .ghost/fingerprint/enforcement/checks.yml --format json
ghost lint --all

Package fidelity - verify

Validate fingerprint evidence and exemplar paths, typed check refs, optional rationale files, and config references.

ghost verify .ghost --root .
ghost verify --all --memory-dir .design/memory

Legacy survey ops - survey <op>

Operate on ghost.survey/v1 files as legacy/cache source material.

Inspection - describe

Print optional .ghost/fingerprint/memory/intent.md or a section map of a direct fingerprint markdown file.

Generate handoff packets - emit

Emit review-command or the context-bundle generation packet from split fingerprint layers. Context bundles emit split files, not an assembled fingerprint.yml.

Deterministic gates - check

Run active ghost.checks/v1 gates against a git diff. Without --package, Ghost groups changed files by resolved fingerprint stack and runs merged checks per group.

Advisory governance packet - review

Emit an evidence-routed advisory review packet grounded in split fingerprint layers, optional memory, checks, and the diff.

Comparison - compare

Pairwise distance or composite analysis over root packages or legacy direct fingerprint markdown.

Drift stance - ack / track / diverge

Compatibility governance verbs for tracked direct fingerprint markdown files.