Reference

Commands, settings and files

The short list of everything pr-brief reads, writes and accepts.

Commands

CommandWhat it doesMain flags
pr-brief initSets a repo up: writes .pr-brief.json, and optionally the PR template and the CI check (a GitHub workflow, or an Azure Pipelines file). --rewrite adds a job that lets the Claude Code GitHub Action write the description (GitHub only; you choose --auth). Never overwrites. With --config inline the style and theme go in the CI file and no .pr-brief.json is written.--pr-template --workflow --host github|azure-devops --config file|inline --rewrite --auth federation|bedrock|vertex|api-key --style S --theme T --dir D
pr-brief shapeReads the git diff and prints the flows to draw, the references, and the files ranked by risk, as JSON.--base REF --head REF --working-tree --title T --dir D
pr-brief diagramDraws one flow as a complete Mermaid diagram in a theme.--flow FILE|- --report FILE --flow-number N --theme T --raw
pr-brief gateChecks a description with fixed rules and no AI. Exit 0 passes, 1 means findings, 2 means a usage or config error. --ci reads a GitHub pull request event; in an Azure pipeline use --stdin. See the gate.--hook --ci --file F --stdin --host github|azure-devops --style S --json
pr-brief lintRuns the ASD-STE100 lint on prose. A Go port of ste-lint.py.--file F --json
pr-brief configReads and writes the settings.show [--json] [--ci] get KEY set KEY VALUE --scope user|repo init validate
pr-brief linksMakes each file in the Read-these-first table a link, so a reviewer opens it from the description. With --pr N the link goes to the file’s diff in the PR, which always shows the latest commit. Without it, the link goes to the file on the branch. It never links to a commit. Prints the new description.--body F --pr N --branch B --remote URL
pr-brief themeLists, shows and validates themes.list show [NAME|FILE] [--json] validate FILE
pr-brief bodyRewrites an existing description safely.improve past restore uncomment
pr-brief versionPrints the version.

Run any command with -h for its flags. The binary is bin/pr-brief in the plugin; it picks the right build for your machine.

Settings and precedence

KeyValuesDefault
styleste+iceberg ste icebergste+iceberg
improve.previousdrop commentdrop
diagram.themea built-in name, or a path to a .json theme filegithub-dark
OrderSourceNotes
1A flag--style on one run. CI ignores flags.
2The repo file .pr-brief.jsonAt the git top-level. Committed, so the whole team shares it. CI reads it from the base commit.
3Your user file ~/.config/pr-brief/config.jsonOr $XDG_CONFIG_HOME/pr-brief/config.json. CI ignores it.
4The defaultste+iceberg, drop, github-dark

Everything else is a fixed convention.

Where things live

WhatWhere
Repo settings.pr-brief.json at the repo root
Your settings~/.config/pr-brief/config.json
Saved descriptions~/.local/state/pr-brief/<host>/<owner>/<repo>/<pr>/<timestamp>-NN.md. One is written before every body improve, whatever the setting. pr-brief body restore prints one.
Theme filesAnywhere for you; inside the repo for a repo config

Markers

<!-- pr-brief:begin v1 style=ste+iceberg theme=github-dark -->
## Brief
...
<!-- pr-brief:end -->

<!-- pr-brief:previous v1 saved=2026-10-05T14:02Z
the earlier human description, every "--" written as "-&#45;"
pr-brief:previous:end -->

> pr-brief skipped: <reason>                  # skip one PR
<!-- pr-brief:no-diagram: <reason> -->          # a small or config-only PR

The begin marker names the style and the theme. When a config names them, the config wins, so a marker cannot weaken the gate. A theme is a built-in name or custom:<8 hex>.

JSON Schemas

SchemaFor
pr-brief.schema.jsonThe settings file. Unknown keys are errors.
pr-brief-theme.schema.jsonA custom theme file.
pr-brief-flow.schema.jsonThe input of pr-brief diagram: node-link shaped, with inputs, nodes, outputs and edges. pr-brief shape emits this shape.

A test keeps each schema in step with the Go types.