108 lines
4.3 KiB
Markdown
108 lines
4.3 KiB
Markdown
# Weatherreporter CLI
|
|
|
|
`weatherreporter generate daily`, `weatherreporter generate tomorrow`,
|
|
`weatherreporter generate three-day`, `weatherreporter generate weekend`,
|
|
`weatherreporter generate storm`,
|
|
`weatherreporter run morning`, and `weatherreporter run evening` currently
|
|
write Markdown reports through `scriptorium`, after writing managed preparation
|
|
artifacts and running `scriptorium render` as a preflight check.
|
|
|
|
## Shortest Useful Command
|
|
|
|
```sh
|
|
weatherreporter generate daily --date 2026-05-29 --out ./daily.md
|
|
```
|
|
|
|
The command parses flags, loads configuration, fetches weather data, builds a
|
|
Daily briefing, writes workspace artifacts, invokes
|
|
`scriptorium render --input data_package=<managed_path> --format json`, then
|
|
invokes `scriptorium run --input data_package=<managed_path> --out <managed_report>`.
|
|
When `--out` is supplied, it also writes a copy of the Markdown report to that
|
|
path.
|
|
|
|
For tomorrow planning:
|
|
|
|
```sh
|
|
weatherreporter generate tomorrow --out ./tomorrow.md
|
|
weatherreporter run evening
|
|
```
|
|
|
|
For the 3-Day Outlook:
|
|
|
|
```sh
|
|
weatherreporter generate three-day --out ./three-day.md
|
|
weatherreporter generate weekend --out ./weekend.md
|
|
```
|
|
|
|
For a focused manual Storm Report:
|
|
|
|
```sh
|
|
weatherreporter generate storm --start 2026-05-29T18:00 --end 2026-05-30T06:00 --out ./storm.md
|
|
```
|
|
|
|
## Command Overview
|
|
|
|
```text
|
|
weatherreporter generate daily
|
|
weatherreporter generate tomorrow
|
|
weatherreporter generate three-day
|
|
weatherreporter generate weekend
|
|
weatherreporter generate storm --start 2026-05-29T18:00 --end 2026-05-30T06:00
|
|
weatherreporter run morning
|
|
weatherreporter run evening
|
|
weatherreporter inspect reports
|
|
weatherreporter inspect metadata RUN_ID
|
|
weatherreporter inspect briefing RUN_ID
|
|
weatherreporter inspect data-package RUN_ID
|
|
weatherreporter inspect prior RUN_ID
|
|
weatherreporter inspect sources RUN_ID
|
|
```
|
|
|
|
`generate daily`, `generate tomorrow`, `generate three-day`,
|
|
`generate weekend`, and `generate storm` write a briefing snapshot, prompt
|
|
input data package, render preflight output, Markdown report, and metadata file
|
|
under the configured workspace. `generate storm` requires explicit `--start`
|
|
and `--end` bounds for the event window. `run evening` generates the Tomorrow
|
|
Planning Brief. `run morning` generates Daily Today and the 3-Day Outlook, plus
|
|
Weekend Outlook except on Sunday. Run commands continue remaining reports after
|
|
an independent report failure, print a JSON aggregate summary to stdout, write
|
|
compact report status logs to stderr, and return nonzero when any report
|
|
failed.
|
|
|
|
`inspect` commands read the configured workspace and emit JSON to stdout. They
|
|
do not fetch weather data or invoke `scriptorium`.
|
|
|
|
## Flags
|
|
|
|
- `-h`, `--help`: show help.
|
|
- `--config PATH`: load configuration from `PATH` instead of `/usr/local/etc/weatherreporter/config.yml`.
|
|
- `--units VALUE`: override configured Weather API units.
|
|
- `--tz NAME`: override configured Weather API timezone.
|
|
- `--out PATH`: optional Markdown report copy for `generate daily`, `generate tomorrow`, `generate three-day`, `generate weekend`, and `generate storm`.
|
|
- `--out-dir PATH`: optional directory for extra Markdown report copies from `run morning` and `run evening`.
|
|
- `--date YYYY-MM-DD`: optional date for `generate daily`; defaults to the current local date in the configured timezone.
|
|
- `--start TIME`: required start time for `generate storm`.
|
|
- `--end TIME`: required end time for `generate storm`.
|
|
- `--limit N`: maximum report records for `inspect reports`; defaults to 20,
|
|
and `0` means no limit.
|
|
|
|
Storm times accept `YYYY-MM-DDTHH:MM` in the configured timezone or RFC3339
|
|
timestamps with explicit offsets.
|
|
|
|
## Inspection
|
|
|
|
```sh
|
|
weatherreporter inspect reports --limit 10
|
|
weatherreporter inspect metadata 20260529T100000.000000000Z_daily_today
|
|
weatherreporter inspect briefing 20260529T100000.000000000Z_daily_today
|
|
weatherreporter inspect data-package 20260529T100000.000000000Z_daily_today
|
|
weatherreporter inspect prior 20260529T100000.000000000Z_daily_today
|
|
weatherreporter inspect sources 20260529T100000.000000000Z_daily_today
|
|
```
|
|
|
|
`inspect reports` lists recent generated runs with artifact paths and warning
|
|
counts. The other commands require a RunID. `inspect prior` returns the prior
|
|
comparable snapshot metadata selected from stored metadata, or `null` when no
|
|
prior comparable snapshot exists. `inspect sources` shows source provenance and
|
|
source warnings without dumping full weather payloads.
|