CLI Reference¶
Generated from sawmill <command> --help. Every command accepts
-h/--help.
Exit status: 0 success; 1 check found a failing target; 2
configuration, manifest, rule-file, discovery or usage error.
sawmill¶
sawmill [OPTIONS] COMMAND [ARGS]...
sawmill LOGFILE # shorthand for `sawmill view LOGFILE`
Option |
Description |
|---|---|
|
Show the version and exit. |
|
Show this message and exit. |
sawmill init¶
sawmill init [OPTIONS]
Create .sawmill/manifest.toml, or append a target to it.
Option |
Value |
Description |
|---|---|---|
|
TEXT |
Manifest name (default: current directory name). |
|
NAME GLOB |
Append a target NAME whose logs match GLOB. |
|
TEXT |
Plugin for |
|
Show this message and exit. |
sawmill view¶
sawmill view [OPTIONS] [TARGET]
Open TARGET, every target of the manifest, or a LOGFILE in the TUI.
Option |
Value |
Description |
|---|---|---|
|
PATH |
Use exactly this manifest; no directory walk. |
|
DIR |
Directory to search for manifests (repeatable). |
|
NAME |
Plugin to parse a log file with. |
|
SEV |
Severity id overriding every target’s fail_on. |
|
NAME=VALUE |
Set a manifest variable (repeatable). |
|
Show this message and exit. |
sawmill check¶
sawmill check [OPTIONS] [TARGET...]
Run manifest targets and exit non-zero on unwaived failures.
Option |
Value |
Description |
|---|---|---|
|
Run every target of every manifest. |
|
|
SEV |
Severity at or above which unwaived messages fail, for every target. |
|
PATH |
Also write the JSON report to PATH. |
|
PATH |
Use exactly this manifest; no directory walk. |
|
DIR |
Directory to search for manifests (repeatable). |
|
NAME=VALUE |
Set a manifest variable (repeatable). |
|
Show this message and exit. |
sawmill report¶
sawmill report [OPTIONS] [TARGET...]
Report on manifest targets; always exits 0 unless the configuration is invalid.
Option |
Value |
Description |
|---|---|---|
|
Report every target of every manifest. |
|
|
SEV |
Severity at or above which unwaived messages fail, for every target. |
|
[json|text|junit] |
Report format. [default: json] |
|
PATH |
Write to PATH. With no PATH, use the
manifest’s |
|
PATH |
Use exactly this manifest; no directory walk. |
|
DIR |
Directory to search for manifests (repeatable). |
|
NAME=VALUE |
Set a manifest variable (repeatable). |
|
Show this message and exit. |
sawmill rules¶
sawmill rules [OPTIONS] COMMAND [ARGS]...
List, audit and generate rules. Subcommands: generate, list, unused.
Option |
Value |
Description |
|---|---|---|
|
Show this message and exit. |
sawmill rules list¶
sawmill rules list [OPTIONS] [TARGET...]
List the rules in scope for each target, in matching order.
Option |
Value |
Description |
|---|---|---|
|
Select every target of every manifest. |
|
|
PATH |
Use exactly this manifest; no directory walk. |
|
DIR |
Directory to search for manifests (repeatable). |
|
Show this message and exit. |
sawmill rules unused¶
sawmill rules unused [OPTIONS] [TARGET...]
Run targets and list rules that matched nothing across the run.
Option |
Value |
Description |
|---|---|---|
|
Run every target of every manifest. |
|
|
PATH |
Use exactly this manifest; no directory walk. |
|
DIR |
Directory to search for manifests (repeatable). |
|
NAME=VALUE |
Set a manifest variable (repeatable). |
|
Show this message and exit. |
sawmill rules generate¶
sawmill rules generate [OPTIONS] TARGET
Run TARGET and print a rule file waiving its unwaived messages.
Option |
Value |
Description |
|---|---|---|
|
N |
Only generate rules for messages at or above severity level N. [default: 1] |
|
PATH |
Use exactly this manifest; no directory walk. |
|
DIR |
Directory to search for manifests (repeatable). |
|
NAME=VALUE |
Set a manifest variable (repeatable). |
|
Show this message and exit. |
sawmill plugins¶
sawmill plugins [OPTIONS] COMMAND [ARGS]...
List and inspect installed plugins. Subcommands: info, list.
Option |
Value |
Description |
|---|---|---|
|
Show this message and exit. |
sawmill plugins list¶
sawmill plugins list [OPTIONS]
List installed plugins.
Option |
Value |
Description |
|---|---|---|
|
Show this message and exit. |
sawmill plugins info¶
sawmill plugins info [OPTIONS] NAME
Show hooks, filters, severity levels and grouping fields for plugin NAME.
Option |
Value |
Description |
|---|---|---|
|
Show this message and exit. |