made-in-common

pnpm-workspace-utils

Utilities for managing pnpm catalogs

by made-in-common

TypeScript

TypeScript100%

Commit activity

Last 12 weeks · 1 commit

Full graph →

Community health

4 of 6 standards met

Community profile →
62
✓README✓License✓Contributing✓Code of Conduct○Issue Template○PR Template

Recent PRs & issues

Active · 3 in progress · Last activity 1d ago
See all on GitHub →
christopher-buss

pnpm 12.15 added an field to . It delegates settings to other YAML files or to config dependencies (docs): pnpm resolves from the included file, and writes new entries there. (1.9.1) reads catalogs only from , so after this split every specifier fails: Request Resolve settings through when the plugin reads the workspace: Read local files listed in (paths start with or , relative to the workspace root) and merge the settings each one owns: , , , or . Report a catalog error at the file that owns the catalog, not at . Make fixes and the rules write to or lint the owning file. Settings delegated to a config dependency () are harder to read without an install. Skipping them, or reading them from when present, would be enough for a first version.

christopher-buss · 1w ago
christopher-buss

What (used first by , and ) found out if the linted is a workspace package by globbing every in the workspace, following symlinks. That cost grows with the size of the repo, and monorepo task runners that start one ESLint process per project pay it in every process. This matches the root-relative path of the linted file against the patterns with picomatch instead, using the same options and pattern normalisation as tinyglobby (, the // ignores, excludes, dropped like tinyglobby does, absolute patterns made relative). No disk walk, no cache. stays for . Numbers In a monorepo with 275 files, one membership check per process went from ~820–950 ms to ~5–7 ms. Membership is identical to the old glob for all 275 files. Intentional differences A matching path is a member even if the file is not on disk yet (e.g. an unsaved new in an editor). re-entry patterns are not simplified the way tinyglobby does. Symlinked package directories are matched by the path ESLint gives, not the resolved target. Testing New cases in : nested patterns with dist/build/node_modules/dot exclusion, a missing file that matches, absolute and Windows-style paths, patterns, and absolute patterns. , and pass. 🤖 Generated with Claude Code

christopher-buss · 2w ago
lonix1

I followed the instructions, but get an error. Below is a minimal reproduction. Test: Notes: If I remove the json config block, then it works If I use in the json config block, then it works; but that means the file will not be linted by other rules and plugins Is this plugin compatible with a config that also lints json?* (PS: above details the JSON problem - maybe the same exists for YAML.)

lonix1 · 3mo ago
cylewaitforit

Clear and concise description of the problem At this time this plugin uses the older language parsers and not the modern language features from eslint. https://eslint.org/docs/latest/use/configure/plugins#specify-a-language This can cause some comparability issues when trying to use with plugins that are executing on the same files. Suggested solution This plugin could use the yaml and json language features from https://github.com/ota-meshi/eslint-plugin-yml#languages and https://github.com/eslint/json Example from another plugin making the json migration to language features. https://github.com/michaelfaith/eslint-plugin-package-json/blob/main/docs/plans/parser-to-language-migration/plan.md Alternative Continuing to only support the legacy parser pattern Additional context _No response_ Validations [x] Follow our Code of Conduct [x] Read the Contributing Guide. [x] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.

cylewaitforit · 3mo ago
christopher-buss

What Adds an opt-in YAML rule that reports pnpm's anonymous top-level key in , for workspaces that standardise on named catalogs. is deliberately not reported — it is already the named form, even though pnpm resolves bare specifiers to it. Notes Not fixable. Rewriting into would silently break every bare specifier across the workspace's files, which a YAML-scoped rule can't rewrite reliably. Report-only seemed the honest option. Not enabled in — preferring named catalogs is a style choice, not a correctness one, so it follows in being registered but opt-in. Follows the existing YAML rule shape (filename guard → → / bail → ), and reports on the key node so the error lands on rather than the whole block. Known interaction worth flagging defaults , and writes when is absent (). So with both rules on, can generate the very this rule then reports, with no autofix to undo it. Setting to a named catalog avoids it, so it is not a blocker — but it's arguably a sign the preference belongs on the write side too. Happy to follow up separately if you think that's worth changing. Testing 6 new cases in (named catalogs, , no catalogs; anonymous alone, alongside named, and empty). Full suite green at 87/87, clean, and the rule passes against this repo's own . 🤖 Generated with Claude Code

christopher-buss · 4mo ago
Structured data for AI agents

Repository: made-in-common/pnpm-workspace-utils. Description: Utilities for managing pnpm catalogs Stars: 138, Forks: 19. Primary language: TypeScript. Languages: TypeScript (100%). License: MIT. Topics: pnpm. Latest release: v1.9.1 (2mo ago). Open PRs: 3, open issues: 7. Last activity: 1d ago. Community health: 62%. Top contributors: antfu, sxzz, privatenumber, ntnyq, jycouet, andreww2012, antfubot, christopher-buss, dvcol, czhlin and others.