Skip to content

CLI reference

The commands below are introspected from the installed package. Invoke any command with -h/--help for full help.

Inspect available component types (core + plugins).

Sub-commands: list

List core + discovered plugin components (source + sandbox status).

Flag / argKindTypeRequiredDefaultDescription
--jsonoptionbooleannoEmit machine-readable JSON instead of the human table.

Show what changes in the generated workflow between two workflow.yaml.

Flag / argKindTypeRequiredDefaultDescription
YAML_Aargumentfileno
YAML_Bargumentfileno
--from-gistoptiontextnoFetch the LEFT-side workflow.yaml from a public GitHub Gist URL and diff against the local YAML path passed as the (one) remaining positional arg. Two-gist diff is not supported in v0. (Phase 8 §2C, decision D2.)
--no-cacheoptionbooleannoWhen —from-gist is set, bypass the local cache and re-fetch.
--formatoptionchoicenounifiedOutput format: a unified text diff, or a JSON {added, removed} structure.
--context, -noptionintegerno3Lines of unified-diff context.

Unprivileged preflight: probe the host this tool will run on.

Flag / argKindTypeRequiredDefaultDescription
WORKFLOW_YAMLargumentfileno
--jsonoptionbooleannoEmit a machine-readable JSON object on stdout (human table -> stderr).
--cylc-run-diroptionpathnoOverride the cylc-run dir to check (default: $CYLC_RUN_DIR or ~/cylc-run).
--min-free-gboptionfloatno2.0Minimum free-space threshold (GB) for yellow/red space checks.
--portoptionintegerno8765GUI port to probe for availability (mirrors gui --port).
--no-coloroptionbooleannoSuppress ANSI colour; useful for log files and CI.

Render a workflow.yaml into a runnable Cylc 8 workflow.

Flag / argKindTypeRequiredDefaultDescription
WORKFLOW_YAMLargumentfileyes
--output, -ooptiondirectorynoOutput directory. Required unless —dry-run.
--dry-runoptionbooleannoRender to stdout instead of writing to —output. (Plan §4.2.)
--engineoptionchoicenocylcExecution engine. Only cylc is implemented; flag exists for future-proofing.
--no-warningsoptionbooleannoSuppress non-fatal soft-warnings (W1–W3) printed to stderr.
--modeoptionchoicenoliveCylc run mode the rendered flow is intended for. ‘dummy’ adds a top-of-file banner reminding the operator to cylc play --main-loop dummy_bridge (per [[project-phase-2-6-cleanup]] memory; OC-1). Does not change the rendered graph — Cylc’s own --mode=dummy is set at play time. The banner is plain text and inert to cylc.

Open the nwp-compose read/operate GUI.

Flag / argKindTypeRequiredDefaultDescription
--portoptionintegerno8765Port for local mode. Falls back to 8000-9000 on collision.
--localoptionbooleannoForce local mode even if config.yaml declares a hosted_url.
--urloptiontextnoOpen this exact URL (overrides config + local mode).
--print-urloptionbooleannoPrint only the bare URL on stdout and exit, without booting a server or opening a browser. Use for shell pipelines like URL=$(nwp-compose gui --print-url). For SSH tunneling, use --no-browser instead (boots the server, prints the announce line).
--no-browseroptionbooleannoBoot the server, print the URL, but do NOT open the browser.
--cylc-run-diroptionpathnoOverride the cylc-run directory (default: ~/cylc-run).
--configoptionpathnoOverride the config file path (default: ~/.nwp-compose/config.yaml).

Assisted migration from a personal bash/cron NWP setup into a starter workflow.yaml.

Flag / argKindTypeRequiredDefaultDescription
--cron, -coptiontextnoSentinel.UNSETA crontab line or schedule (the hour field drives the cycling cadence), e.g. ‘0 0,6,12,18 * * *’.
--script, -soptionfilenoSentinel.UNSETA driver bash script to scan for model executables.
--output, -ooptionfilenoimported-workflow.yamlStarter workflow.yaml to write.
--reportoptionfilenoMigration report path (default: <output>.MIGRATION.md).
--forceoptionbooleannoOverwrite the output/report if they exist.
--validate-afteroptionbooleannoRun nwp-compose validate on the generated starter and report the result.

Upgrade a workflow.yaml to the current schema version with a visible diff.

Flag / argKindTypeRequiredDefaultDescription
WORKFLOW_YAMLargumentfileyes
--write, -woptionbooleannoOverwrite the file in place (after backing it up to <file>.bak). Default is dry-run: show the diff, write nothing.
--forceoptionbooleannoPermit clobbering an existing <file>.bak when writing.
--tooptionintegernoTarget schema version (default: current = 0).

Interactively configure a component’s namelist (templated or BYO).

Flag / argKindTypeRequiredDefaultDescription
-c, --componentoptiontextyesSentinel.UNSETComponent type to configure (wrf, real, or geogrid in this build).
--modeoptionchoiceyesSentinel.UNSETtemplated: prompt schema params + preview render. byo: dry-run patch your own namelist’s cycle keys.
--byo-fileoptionfilenoBYO mode: path to your existing namelist file (required for —mode byo).
--dry-runoptionbooleannoPreview only — write no files and exit 0.
-o, --outputoptionfilenoTemplated mode: workflow.yaml to create/update (default ./workflow.yaml).
--forceoptionbooleannoTemplated mode: overwrite —output if it already exists.
--no-warningsoptionbooleannoTemplated mode: suppress soft warnings (does not suppress the W-7..W-10 unphysical block).

Scaffold a starter workflow.yaml from a known-good template or a gist URL.

Flag / argKindTypeRequiredDefaultDescription
--templateoptiontextnoTemplate to scaffold (run nwp-compose new --template ? for the list).
--from-gistoptiontextnoFetch a workflow.yaml from a public GitHub Gist URL (supports the #filename selector for multi-file gists). Mutually exclusive with —template. (Phase 8 §2C.)
--no-cacheoptionbooleannoWhen —from-gist is set, bypass the local cache and re-fetch.
--output, -ooptionfilenoDestination YAML file. Defaults to ./&lt;template&gt;.yaml or ./workflow.yaml.
--forceoptionbooleannoOverwrite the destination file if it already exists.

Validate, generate, install, and play a workflow.yaml in one command.

Flag / argKindTypeRequiredDefaultDescription
WORKFLOW_YAMLargumentfileyes
--output, -ooptiondirectorynoOutput directory for generate. Defaults to ./out/ beside the YAML.
--dummyoptionbooleannoGenerate with —mode=dummy, then play with —mode=dummy —main-loop dummy_bridge. Exercises the graph without real binaries (aliases cluster platforms to localhost background so the dummy play runs on a box without SLURM).
--dry-runoptionbooleannoStop after generate; print the workflow id and the exact cylc commands that WOULD run. No install, no scheduler.
--no-playoptionbooleannoRun validate + generate + cylc install, but stop before cylc play.
--no-warningsoptionbooleannoPass —no-warnings through to validate + generate (suppresses W1–W6).

Introspect the component schema (GUI exporter, etc.).

Sub-commands: widgets

Emit per-component GUI form-field descriptors as JSON.

Flag / argKindTypeRequiredDefaultDescription
--component, -coptiontextnoExport only this component_type (default: all components).
--output, -ooptionfilenoWrite JSON to this path instead of stdout.
--indentoptionintegerno2JSON indent (use 0 for compact single-line output).

Guided, exitable walkthrough that builds a valid workflow.yaml.

Flag / argKindTypeRequiredDefaultDescription
--output, -ooptionfilenotutorial-workflow.yamlDestination YAML. Written ONLY at the final confirm step.
--forceoptionbooleannoOverwrite the destination file if it already exists.
--non-interactiveoptionbooleannoRun the full arc with defaults — no prompts, no network. CI-safe.
--replayoptionfilenoLoad an existing YAML and replay the tutorial against its choices as defaults. Mutually exclusive with —non-interactive.
--engineoptionchoicenompasWhich NWP path to walk (selects the lesson + starting template).
--chapteroptioninteger rangenoJump straight to one chapter (1–6), print it, and exit.

Validate a workflow.yaml against the schema and graph rules.

Flag / argKindTypeRequiredDefaultDescription
WORKFLOW_YAMLargumentfileno
--from-gistoptiontextnoFetch a workflow.yaml from a public GitHub Gist URL and validate in place — never writes to disk. Mutually exclusive with the positional workflow_yaml argument. (Phase 8 §2C.)
--no-cacheoptionbooleannoWhen —from-gist is set, bypass the local cache and re-fetch.
--cylcoptionbooleannoAfter schema validation, render to a tempdir and run cylc validate.
--no-warningsoptionbooleannoSuppress non-fatal soft-warnings (W1–W6).