Skip to content

CLI Reference ​

Every public dotbrain command, grouped by task. Run any command with --help for the same information in the terminal.

Human reports group changes and problems by target, shorten home paths to ~, and use tables for catalogs and project inspection. Empty lists, previews, and skipped work are explicit. Doctor shows problems and warnings first; use doctor -v to include every healthy check. Runtime activation and session uncertainty are informational, shown with doctor -v and in JSON; they do not count as passed checks. Missing registered hook files and failed plugin checks remain warnings. Colors follow terminal capabilities; redirected output stays plain.

Finite reports support --json: stdout contains one result with command, overall status, per-target results, and errors. Finding severities are info, warning, and error; warnings alone do not cause failure. Exit codes are 0 for success, 1 for operational failure or a partially failed batch, and 2 for invalid invocation or selection.

JSON consumers must replace checks for severity: advisory with severity: warning. The old severity is no longer emitted; other result fields and exit codes are unchanged.

Commands at a Glance ​

CommandDoes
bootstrapPrepare this machine for dotbrain: global skill and subagent links.
doctorRead-only health check of machine readiness and selected project setup.
wireCreate a Brainspace or attach a checkout, including a linked worktree.
refreshRepair setup while preserving project declarations and content.
unwireDetach a checkout while retaining its Brainspace and tracker databases.
projects listList every registered project using local declarations and wiring.
projects showInspect the current wired project or a named project's registered checkout.
skills listDiscover locally available skills.
skills linkReconcile selected skills in project or explicit global scope.
agents listDiscover locally available agents.
agents linkReconcile selected agents in project or explicit global scope.
beads syncSync declared local tracker bindings and pull configured remotes; never push.
beads migrateMigrate embedded trackers to a server, keeping history and rollback backups.
beads list-dbList remote database identifiers, including databases without a Brainspace.
beads drop-dbExplicitly delete a remote database; never infer it from the current project.
site initGive a Brain a site: create .brain/site/ with site.yaml, the home page, and the manual.
site devServe the Brain site locally with live reload (127.0.0.1).
site buildBuild the Brain site; fails on a nav link to a missing page.
site previewServe the last build locally (127.0.0.1).
hook session-startEmit a wired repo's Brain context.

Setup ​

Prepare a machine and check its health. See Getting started.

dotbrain bootstrap ​

Prepare this machine for dotbrain: global skill and subagent links.

text
dotbrain bootstrap [OPTIONS]
OptionDefaultDescription
--home path—Override the private data root.
--runtime textallFilter runtimes: claude, codex, or all.
--json—Emit one structured result.

dotbrain doctor ​

Read-only health check of machine readiness and selected project setup.

text
dotbrain doctor [OPTIONS]
OptionDefaultDescription
--home path—Override the private data root.
--project text—Select a named Brainspace.
--all—Inspect every registered project.
--verbose, -v—Include healthy checks and informational context.
--json—Emit one structured result.

Projects ​

Connect code repos to Brainspaces and keep them in sync. See Wiring.

dotbrain wire ​

Create a Brainspace or attach a checkout, including a linked worktree.

text
dotbrain wire [OPTIONS]
OptionDefaultDescription
--repo path—Checkout to attach; defaults to the current Git checkout.
--project text—Select a named Brainspace.
--no-repo—Create a Brain-only project; requires --project.
--skip-beads—Create without a tracker.
--remote text—Dolt remote for initial tracker creation.
--server-host text—Dolt server host; defaults to config.
--server-port text—Dolt server port; defaults to config.
--server-user text—Dolt server user; defaults to config.
--database text—Tracker database; defaults to project name.
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain refresh ​

Repair setup while preserving project declarations and content.

text
dotbrain refresh [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--all—Refresh all registered projects.
--home path—Override the private data root.
--runtime textallFilter runtimes: claude, codex, or all.
--json—Emit one structured result.

dotbrain unwire ​

Detach a checkout while retaining its Brainspace and tracker databases.

text
dotbrain unwire [OPTIONS]
OptionDefaultDescription
--repo path—Checkout to detach.
--project text—Select a named Brainspace.
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain projects list ​

List every registered project using local declarations and wiring.

text
dotbrain projects list [OPTIONS]
OptionDefaultDescription
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain projects show ​

Inspect the current wired project or a named project's registered checkout.

text
dotbrain projects show [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--home path—Override the private data root.
--json—Emit one structured result.

Skills and agents ​

Link skills and vendor-native subagents into agent runtimes. See Skills.

dotbrain skills list ​

Discover locally available skills.

text
dotbrain skills list [OPTIONS]
OptionDefaultDescription
--home path—Override the private data root.
--runtime textallFilter runtimes: claude, codex, or all.
--project text—Show selections for a named Brainspace.
--json—Emit one structured result.

Reconcile selected skills in project or explicit global scope.

text
dotbrain skills link [OPTIONS]
OptionDefaultDescription
--home path—Override the private data root.
--runtime textallFilter runtimes: claude, codex, or all.
--scope textprojectDelivery scope: project or global.
--project text—Select a named Brainspace.
--repo path—Select a wired checkout; defaults to the current checkout.
--all—Reconcile every registered project.
--json—Emit one structured result.

dotbrain agents list ​

Discover locally available agents.

text
dotbrain agents list [OPTIONS]
OptionDefaultDescription
--home path—Override the private data root.
--runtime textallFilter runtimes: claude, codex, or all.
--project text—Show selections for a named Brainspace.
--json—Emit one structured result.

Reconcile selected agents in project or explicit global scope.

text
dotbrain agents link [OPTIONS]
OptionDefaultDescription
--home path—Override the private data root.
--runtime textallFilter runtimes: claude, codex, or all.
--scope textprojectDelivery scope: project or global.
--project text—Select a named Brainspace.
--repo path—Select a wired checkout; defaults to the current checkout.
--all—Reconcile every registered project.
--json—Emit one structured result.

Beads ​

Manage the Beads tracker's state and backend. See Beads backend.

dotbrain beads sync ​

Sync declared local tracker bindings and pull configured remotes; never push.

text
dotbrain beads sync [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--all—Sync every registered project.
--dry-run—Preview tracker sync and configured pulls.
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain beads migrate ​

Migrate embedded trackers to a server, keeping history and rollback backups.

text
dotbrain beads migrate [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--all—Migrate every registered project.
--server-host text—Target Dolt server host; defaults to config.
--server-port text—Target Dolt server port; defaults to config.
--server-user text—Target Dolt server user; defaults to config.
--database text—Database override for a single project.
--dry-run—Preview the history-preserving migration.
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain beads list-db ​

List remote database identifiers, including databases without a Brainspace.

text
dotbrain beads list-db [OPTIONS]
OptionDefaultDescription
--server-host text—Dolt server host; defaults to config.
--server-port text—Dolt server port; defaults to config.
--server-user text—Dolt server user; defaults to config.
--ssh-host text—Optional SSH hop; defaults to config.
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain beads drop-db ​

Explicitly delete a remote database; never infer it from the current project.

text
dotbrain beads drop-db [OPTIONS] NAME
ArgumentDescription
NAMEDatabase identifier, including an orphaned database.
OptionDefaultDescription
--yes—Confirm the destructive drop.
--dry-run—Preview without deleting.
--server-host text—Dolt server host; defaults to config.
--server-port text—Dolt server port; defaults to config.
--server-user text—Dolt server user; defaults to config.
--ssh-host text—Optional SSH hop; defaults to config.
--home path—Override the private data root.
--json—Emit one structured result.

Brain site ​

Set up and run a Brain's private site. See Brain site.

dotbrain site init ​

Give a Brain a site: create .brain/site/ with site.yaml, the home page, and the manual.

text
dotbrain site init [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--title text—Site title. Defaults to '<name> Brain'.
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain site dev ​

Serve the Brain site locally with live reload (127.0.0.1).

text
dotbrain site dev [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--home path—Override the private data root.

dotbrain site build ​

Build the Brain site; fails on a nav link to a missing page.

text
dotbrain site build [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--home path—Override the private data root.
--json—Emit one structured result.

dotbrain site preview ​

Serve the last build locally (127.0.0.1).

text
dotbrain site preview [OPTIONS]
OptionDefaultDescription
--project text—Select a named Brainspace.
--home path—Override the private data root.

Internal ​

Run by the plugin's hooks, not by hand. See Session context.

dotbrain hook session-start ​

Emit a wired repo's Brain context. Fail-open: silent and exit 0 when there is none.

text
dotbrain hook session-start [ARGS]
ArgumentDescription
ARGS—

Released under the MIT License.