retrofit0.10.0-wip.8

retrofit schema ref-tables

Read or edit a schema's reference-data capture policy.

A table declared as reference data holds the rows the application reads but
never writes, such as currency codes, country lists and status enumerations.
Rows the application writes are seed or transition data and are not declared
here.

The declaration is an attribute of the table's element, carried in the oplog:
add and remove append one SetReferenceData op per resolved table. Nothing is
stored in retrofit.toml, and the declaration survives a rename because it
lives on the element rather than on its name.

The declared set is the reference capture scope of every producer run: import,
data capture, drift and data scaffold each read the set at their own minting
cut and capture a declared table's rows as reference data.

The bare parent reads and reports the declared set. add and remove edit it and
then report the whole result; there is deliberately no list subcommand.

Each argument is an exact relname or a filepath.Match glob, resolved against
the live tables of the read cut: HEAD unless --at <opid> names one. A name
that resolves to nothing is refused: a declaration names a live element, so
the table must exist before it can be declared. A glob is never stored; the
resolved table names are what the oplog carries.

Usage:
  retrofit schema ref-tables [flags]
  retrofit schema ref-tables [command]

Available Commands:
  add         Declare one or more tables as the schema's reference data
  remove      Undeclare one or more of the schema's reference-data tables

Flags:
      --at <opid>             read cut <opid> (HEAD when omitted)
      --data-root data_root   root that overrides the schema's data_root
  -h, --help                  help for ref-tables
      --help-all              show extended help (vocabulary, semantics, caveats)
      --schema <name>         registered schema <name> (resolves via the chain when omitted)

Global Flags:
      --as string        output mode: text | json (default "text")
  -C, --chdir string     treat <dir> as the working directory for the entire run
      --config string    retrofit.toml path (overrides discovery; also accepts $RETROFIT_CONFIG)
  -f, --file string      oplog file path; selects a registered [[schema]] path (overrides discovery)
      --no-consolidate   render every advisory occurrence instead of collapsing repeats
  -q, --quiet count      suppress the advisory tier on stderr; stack (-qq) to drop it whole (errors and results still print)
  -v, --verbose          reveal info-tier advisories on stderr

Use "retrofit schema ref-tables [command] --help" for more information about a command.

Docs: https://docs.retrofit.sh/current/commands/retrofit-schema-ref-tables/

Before 1.0, any release may change behavior; the release notes list what changed.