@kaynooo/cli-check 0.9.0 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -44,6 +44,7 @@ Athome repos run their tools in a container, so `check`, `fix` and `errs -- <com
44
44
  - No `docker` on the PATH (a devcontainer, CI): there is no container to reach, so the step runs on the host and stderr says `host, docker not found` once per project; `--in <service>` fails instead.
45
45
  - A compose file that does not parse fails the call naming the file and the parse error, and points at `--host`; it never falls back to the host silently, even without docker.
46
46
  - `--slot` queues the whole docker command. `--timeout` ends the `docker compose exec` client, which does not always end what it started inside the container.
47
+ - `check --changed` (`-c`) narrows `lint` to the changed source files (staged, unstaged and untracked, against HEAD) when its script is a bare `keslint`, `eslint` or `oxlint`, and `test` to the changed test files and the tests next to changed sources (same folder, `tests/`, `../tests/`) when its script is a bare `bun test`. Every other step runs in full and its line says so, a test step finding no test for the diff included. The typecheck is never narrowed.
47
48
  - `fix` runs the project's scripts and `php-cs-fixer` in the service, and keeps its own formatters (`justfile`, `go`, `rust`, `python`, `makefile`) on the host. The recursion guard variable is passed into the container.
48
49
 
49
50
  ## Output
@@ -97,6 +98,10 @@ Turns tsc, tsgo and vue-tsc (plain and pretty), bun check, eslint and keslint (s
97
98
  | `phpstan` | the default table, `--error-format=raw` and `json` | message: `file:line: message (identifier)`, a wrapped table message joined, problems with no file at line 0 |
98
99
  | `php-cs-fixer` | `fix --dry-run` (`-v` names the fixers, `--diff` is skipped) | file: `file:0:0: style issues to fix (fixer, fixer)` |
99
100
  | `playwright` | the list and line reporters | failed test: the spec file and line of the first stack frame, the first error line and `expected X, received Y`. A test that passed on retry is flaky and not reported |
101
+ | `go` | `go build`, `go vet` and `go test` compile errors | compiler message: `file:line:col: message`, paths as Go prints them (`./main.go`) |
102
+ | `cargo` | rustc's human format | diagnostic: `file:line:col: message (E0308)`, the code frame skipped, warnings prefixed `warning:` |
103
+ | `ruff` | `check` in the concise format and the full one (header plus `-->` line) | diagnostic: `file:line:col: message (F401)` |
104
+ | `pytest` | the failures and errors sections | failure: the location `file:line` of the assertion or exception with its `E` line; with `--tb=short` or a collection error the last frame carries the `E` line. Ruff and pytest are not installed here, so their fixtures are written from the documented output |
100
105
  | `vitest` | the default and verbose reporters | failed test, or suite that failed to load, at its first `file:line:col` frame |
101
106
 
102
107
  `--json` prints `{errors: [{tool, file, line, column, rule?, severity, message, test?}], unrecognised, log?, code?}`, `tool` one of `tsc`, `eslint`, `bun check`, `bun test`, `vitest`, `playwright`, `phpunit`, `phpstan`, `php-cs-fixer`, `go`, `cargo`, `ruff` or `pytest`. Lines no format recognised are never dropped silently: their count goes to stderr, with the path of the full log. A command run after `--` has its whole output saved with the same log writer as `out`, and `log` is that file (the file given when a log is read, nothing for stdin). A first argument that is neither an option nor an existing file starts the command, so the `--` is optional. A command runs in the compose service mounting the current folder like a `check` step does (see above), `--in` and `--host` applying only to a command; a service that is down exits 1 with the service named.