@webority/repo-checks 0.122.0 → 0.125.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 +8 -0
- package/dist/repo-checks.js +95 -41
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -13,6 +13,7 @@ markup and script file of the repository (bootstrap-ui.md → Tokens).
|
|
|
13
13
|
pnpm add -D --save-exact @webority/repo-checks
|
|
14
14
|
pnpm exec webority-repo-checks # every app in the repository
|
|
15
15
|
pnpm exec webority-repo-checks apps/portal # one app folder
|
|
16
|
+
pnpm exec webority-repo-checks --offline # no advisory audit, so no network
|
|
16
17
|
```
|
|
17
18
|
|
|
18
19
|
An app is a `package.json` whose `dependencies` hold `react-native` (mobile) or `react-dom` (web). A `react-dom` folder that also has `react-native-web` is a react-native-web demo: it gets the pnpm and Biome checks, not the portal rules. Biome and `@webority/biome-config` are read from the `package.json` beside the `biome.json` in effect (a nested config with `"root": false` defers to the one above), so a sub-folder linted by the root config does not repeat them. A `workspace:`, `file:` or `link:` reference is local and never counts as a lockstep version.
|
|
@@ -61,6 +62,9 @@ The `missing-export:<file>` check runs the Biome installed beside the app or in
|
|
|
61
62
|
| `oversize:<file>` | A `.jsx`, `.tsx` or `.cshtml` file over 600 lines (over 800 says to split it along its concerns). A warning only: it never fails, even outside the baseline. Counted per file. |
|
|
62
63
|
| `hook:drift` | The root `.husky/pre-commit` is missing or differs from the shared hook this package ships (CRLF is ignored) |
|
|
63
64
|
| `tracked-case:<path>` | A tracked file or folder whose name on disk differs only by letter case, a rename done by hand on a Mac that git never saw; a Linux checkout cannot find the import. Run the `git mv` the message gives. A folder is reported once. Always fails. |
|
|
65
|
+
| `advisory:<package>:<id>` | `pnpm audit` lists a known advisory for the lockfile that governs an app. A `high` or `critical` advisory fails; any other severity warns. Reported on the folder of that `pnpm-lock.yaml` |
|
|
66
|
+
| `advisory:unreachable` | `pnpm audit` could not reach the advisory service. It fails: check the network and run again, or pass `--offline` |
|
|
67
|
+
| `advisory:unreadable` | `pnpm audit` returned a report the check cannot read. It fails |
|
|
64
68
|
|
|
65
69
|
Comment lines (`//`, `/*`, `*`) and `.test.` or `.spec.` files are not read by the import checks.
|
|
66
70
|
|
|
@@ -110,6 +114,10 @@ src/assets/styles/_home.scss:12: color: var(--wui-primary);
|
|
|
110
114
|
`REPO_CHECKS_ENFORCE` names them: `REPO_CHECKS_ENFORCE=lint,rn-mainactivity-oncreate-bundle`, or `all`. A release
|
|
111
115
|
removes a rule from the warning list when no repository has a hit. `--json` carries the warnings under `warnings`.
|
|
112
116
|
|
|
117
|
+
## The advisory audit
|
|
118
|
+
|
|
119
|
+
Each run audits every distinct `pnpm-lock.yaml` that governs a checked app, once per lockfile, with `pnpm audit --json` from that lockfile's folder. The audit has a 60-second timeout and needs the network. An advisory accepted by the owner is recorded with `--baseline-accept <lockfile folder> --reason <text>`, like any other finding. `--offline` skips the audit and prints `repo-checks: advisory rule skipped (--offline).` to stderr, for a machine without the network.
|
|
120
|
+
|
|
113
121
|
## Existing findings: a baseline that only shrinks
|
|
114
122
|
|
|
115
123
|
A repository adopting the checks records what it has today, once:
|