@kaisers-io/refs 0.13.1 → 0.14.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/CHANGELOG.md +70 -0
- package/dist/refs.mjs +43 -43
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,76 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.14.0] - 2026-09-13
|
|
9
|
+
|
|
10
|
+
### Upgrading
|
|
11
|
+
|
|
12
|
+
**A repository declaring a workspace pattern like `packages/**` now reports every member behind
|
|
13
|
+
it.** Those patterns were refused outright, which also stood the unregistered-package pass down for
|
|
14
|
+
the whole ref — so a ref that reported nothing for months may suddenly name hundreds of packages.
|
|
15
|
+
They are not new; they were invisible. `refs doctor` prints the first ten and a count of the rest,
|
|
16
|
+
`refs doctor --json` carries all of them, and
|
|
17
|
+
`refs edit --package=<name> --decline --path=<path> <ref>` records the ones you do not want so they
|
|
18
|
+
stop coming back.
|
|
19
|
+
|
|
20
|
+
### Added
|
|
21
|
+
|
|
22
|
+
- **A workspace pattern that matches at more than one depth is expanded.** `packages/**/*` — the
|
|
23
|
+
most common pnpm spelling — was reported as `unsupported_pattern`, which also made the whole scan
|
|
24
|
+
unreliable and stood the unregistered-package pass down for that ref. A repository declaring it
|
|
25
|
+
got no answer at all, permanently.
|
|
26
|
+
|
|
27
|
+
Such a pattern is now walked from the deepest directory it names outright. Pruning is the
|
|
28
|
+
MATCHER's decision: minimatch answers "could anything below this directory still match?", so a
|
|
29
|
+
subtree no pattern can reach is never entered, a hidden directory is skipped where a wildcard
|
|
30
|
+
would not select it and walked where a pattern names it, and a package boundary does not stop
|
|
31
|
+
the walk — nested packages are ordinary, and both resolvers glob manifest paths rather than
|
|
32
|
+
stopping at one. Selection matches the manifest path for the same reason: `packages/core/**`
|
|
33
|
+
selects `packages/core` itself, because `**` matches zero segments before the manifest.
|
|
34
|
+
`node_modules` and `.git` are never walked under any pattern — a recursive pattern matches an
|
|
35
|
+
installed dependency's path as a string, and reporting those would be reporting a repository's
|
|
36
|
+
dependencies as its own packages.
|
|
37
|
+
|
|
38
|
+
The whole scan runs under one budget shared by every pattern — 32 levels deep, 20 000
|
|
39
|
+
directories, 200 000 entries — because patterns overlap, and a per-pattern budget would charge
|
|
40
|
+
the same tree once per declaration. Reaching a limit is not itself a failure; having to leave a
|
|
41
|
+
subtree that could still match unwalked is, and that is the only condition `scan_budget_exhausted`
|
|
42
|
+
is reported under. A directory the pattern names but the repository does not have stays silent,
|
|
43
|
+
which is ordinary: astro declares `smoke/**/*` and a fresh clone has no `smoke/`.
|
|
44
|
+
|
|
45
|
+
Measured against the resolvers themselves, on fresh clones: `withastro/astro` now detects 554
|
|
46
|
+
packages where pnpm's own workspace listing reports 554 and refs previously reported 37;
|
|
47
|
+
`vercel/next.js` detects 38 where pnpm reports 38; `payloadcms/payload` 53 where pnpm reports 53.
|
|
48
|
+
Pattern semantics were checked against `@npmcli/map-workspaces` over six pattern shapes.
|
|
49
|
+
|
|
50
|
+
- **A ref with hundreds of findings no longer prints all of them.** The same repositories that
|
|
51
|
+
motivated the expansion can legitimately have hundreds of workspace members, so a ref tracking
|
|
52
|
+
three of them would print 551 repair commands into one `doctor` line. Ten are printed, followed
|
|
53
|
+
by a count of what was held back — act on those and run the check again for the next batch.
|
|
54
|
+
`refs doctor --json` carries every finding on the check itself, uncapped: a finding no command
|
|
55
|
+
can repair is never cleared by acting on the ones printed before it, so a capped list would put
|
|
56
|
+
it permanently out of reach.
|
|
57
|
+
|
|
58
|
+
- **A drift finding you have decided against can be recorded, so it stops coming back.**
|
|
59
|
+
`refs doctor` reports every workspace member a checkout declares that the configuration does not
|
|
60
|
+
have. There was no way to say "I looked, and no": the finding returned on every run forever, so
|
|
61
|
+
`config-drift` sat on `warn` permanently and the next real finding arrived in a line already
|
|
62
|
+
being ignored. On a home tracking four monorepos, six of seven findings were decisions that had
|
|
63
|
+
already been made — a repository root, and four packages published nowhere.
|
|
64
|
+
|
|
65
|
+
`refs edit --package=<name> --decline --path=<path> <ref>` records the decision on the ref, as
|
|
66
|
+
the name AND the path. Neither identifies it alone: a name-only record would also silence a
|
|
67
|
+
different package that later takes the name, and a path-only one would silence whatever moves in.
|
|
68
|
+
The `unregistered` finding now prints this command beside the registration command, so both
|
|
69
|
+
answers are available where the question is asked.
|
|
70
|
+
|
|
71
|
+
What a decline does not do: it never touches a finding about a configured entry (`missing`,
|
|
72
|
+
`relocated`, `ambiguous`, `unverifiable`), never suppresses `discovery_incomplete`, and never
|
|
73
|
+
hides the other claimants of an ambiguous name. The package is reported again if it moves.
|
|
74
|
+
`--undecline` withdraws the decision; registering the package clears it in the same write.
|
|
75
|
+
`refs doctor` says how many decisions a run left unreported, so a quiet check is not a silent
|
|
76
|
+
one.
|
|
77
|
+
|
|
8
78
|
## [0.13.1] - 2026-09-12
|
|
9
79
|
|
|
10
80
|
### Upgrading
|