dev gate

Run the verification gate's checks and report each one's outcome and duration

Command version
0.0.0
Command configuration
dev-tool:dev.gate@0.0.0

Arguments

ArgumentTypeRequiredDefaultDescription
--recurse, --no-recursebooleanNofalseRun each check across the repositories this one pins: --recurse is added to every check whose command declares it, and how each crosses is that command's own --recurse-mode, as its argDefaults state it. A check whose command takes no such flag reads the tree the way it always does. Without it every check covers this repository alone
--all, --no-allbooleanNofalseRun every check the gate holds, wherever each is placed. Without it or --ci the checks placed ci are not run, and the report names them. Refused with --ci
--ci, --no-cibooleanNofalseRun the checks placed both and ci, and leave out the ones placed local, which the report names. --only then names checks among the ones that run: a local check it names is still left out
--onlylist[string]No[]Run only the checks of these commands, each named as it is invoked -- lint, type check -- wherever each is placed, except that under --ci one placed local is still left out. A command the gate does not hold is refused, and so is --only with --skip. It is how one part of a gate is run on its ownRepeatable
--skiplist[string]No[]Leave out the checks of these commands, named as --only names them, and run the rest. The other half of a gate that --only ran part of somewhere elseRepeatable
--pathslist[string]No[]Narrow every check that runs to these paths, relative to the repository root: each is given them as its own --paths. A check whose command takes no --paths cannot be narrowed and would run whole under a request for part, so the run is refused naming it; pass --only with the checks that read a pathRepeatable
--check, --no-checkbooleanNofalseRefuse a gate that wrote to the working tree. format and lint --fix repair what they find, which suits a run after an edit and not a run judging finished work: a gate that repaired the tree and passed has reported the opposite of what it found. With this the working tree is read before the checks and after them -- what git reports as changed, and the change itself, across every pinned checkout -- and a difference fails the gate as GATE_WROTE_TO_THE_TREE, naming what moved
--dry-run, --no-dry-runbooleanNofalseRun nothing, and report the checks this run would have run: each by its name, the command it is of and whether that command takes --paths, with the checks it leaves out named as any run names them

It also takes the global arguments.

Output

It answers with a gate.gateReport.

Types

gate.gateReport

FieldTypeRequiredDefaultDescription
dryRunbooleanNofalseWhether this was a dry run (--dry-run), which runs no check and reports planned.
plannedlist[gate.gatePlanned]No[]The checks a dry run would have run, in the order it would have run them. Empty for a run that ran its checks, which reports them as checks.
checkslist[gate.gateCheck]No[]Every check the gate holds, in the order it ran them. All of them run, whatever an earlier one answered.
failedCountintegerNo0How many checks failed.
durationMsintegerNo0How long the whole gate took, in whole milliseconds.
recursebooleanNofalseWhether the checks ran across the repositories this one pins.
leftToCilist[string]No[]The checks the gate holds and this run left to CI, as the list names them: the ones placed ci, in a run with neither --ci nor --all.
leftToLocallist[string]No[]The checks the gate holds and this run left to a session's gate, as the list names them: the ones placed local, in a run with --ci.
writtenlist[string]No[]What the checks changed in the working tree, as git status names each path, for a run asked to refuse a gate that writes (--check). Empty for a gate that left the tree as it found it, and for a run that did not ask.

gate.gatePlanned

FieldTypeRequiredDefaultDescription
namestringYesThe check as the repository's gate list states it.
commandstringYesThe command the check is of, as it is invoked, which is what --only and --skip name.
takesPathsbooleanYesWhether the command takes --paths, so the check can be narrowed to part of a repository.

gate.gateCheck

FieldTypeRequiredDefaultDescription
namestringYesThe check as the repository's gate list states it, which is what it is called wherever it is reported.
outcomeenum one of passed, failedYesWhether the check passed. A check that could not be started failed.
exitCodeintegerYesThe exit code the check's process ended with.
durationMsintegerYesHow long the check took, in whole milliseconds, from starting its process to its exit.
outputstringNo""The end of what a failed check wrote, both streams in the order they were written. Empty for a check that passed: its output reached the console as it ran, and a report carrying every passing check's output is one nobody reads the verdict out of.