Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Pnpm Knowledge Patch?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/nevaberry-pnpm-knowledge-patch)
---
name: pnpm-knowledge-patch
description: pnpm
version: "12.25.1"
license: MIT
metadata:
author: Nevaberry
---
# pnpm Knowledge Patch
Use this skill when migrating pnpm settings, diagnosing installs or workspace
commands, configuring dependency permissions, or managing runtimes and releases.
Read the relevant reference for the conditions and release-specific behavior.
| Reference | Topics |
| --- | --- |
| [Migration and build security](references/migration-and-build-security.md) | Upgrade prerequisites, removed commands, build approvals, permissions, agent skills |
| [Configuration and workspaces](references/configuration-and-workspaces.md) | Config files, environment, manifests, plugins, hooks, filters, catalogs, overrides, patches |
| [Installation, lockfiles, and stores](references/installation-lockfiles-and-store.md) | Install and cleanup, frozen lockfiles, peers, platforms, linkers, caches, deploy, Python and Cargo dependencies |
| [Registries, publishing, and supply chain](references/registries-publishing-and-supply-chain.md) | Routing, authentication, TLS, trust, release age, integrity, audit, SBOM, packing, publishing, revisions |
| [CLI, scripts, and runtimes](references/cli-scripts-and-runtimes.md) | Command dispatch, output, script environments, verification, tasks, pipelines, global tools, runtimes |
| [Releases and updates](references/releases-and-updates.md) | pnpm pins, self-update, dependency updates, GitHub Actions, release intents, lanes, changelogs |
## Migration and removed behavior
For migration from pnpm 10 to 11, or directly from 10 to 12, run the codemod
from the project directory:
```sh
pnpx codemod run pnpm-v10-to-v11
```
It migrates settings and updates `packageManager` to the target pnpm 11 version.
It carries CVE IDs into `auditConfig.ignoreGhsas` for manual conversion.
It moves root `useNodeVersion` to `devEngines.runtime`; migrate a member's
`executionEnv.nodeVersion` manually in that member's `package.json`.
pnpm 11 is pure ESM, requires Node.js 22 or later, and requires glibc 2.27 or
later for its Linux standalone executable.
In pnpm 11, move pnpm settings from the `package.json` `pnpm` field and `.npmrc`
to `pnpm-workspace.yaml` or global `~/.config/pnpm/config.yaml`. Registry and
authentication settings remain in `.npmrc`, pnpm's global `rc`, or `auth.ini`.
Use `packageConfigs` for per-package workspace settings.
Replace the old package-manager mismatch settings with `pmOnFail`:
| Previous setting | Replacement |
| --- | --- |
| `managePackageManagerVersions: true` | `pmOnFail: download` (default) |
| `managePackageManagerVersions: false` | `pmOnFail: ignore` |
| `packageManagerStrict: false` or `COREPACK_ENABLE_STRICT=0` | `pmOnFail: warn` |
| `packageManagerStrictVersion: true` | `pmOnFail: error` |
In pnpm 11, `allowNonAppliedPatches` becomes `allowUnusedPatches`;
`ignorePatchFailures` is removed and patch failures stop installation.
`pnpm link` requires a filesystem path; use `pnpm add -g .` for the current
directory's global install. Run `pnpm setup` for the new `PNPM_HOME/bin` path.
`pnpm runtime set node` supersedes `pnpm env use` in pnpm 11. Its downloaded
Node.js runtimes omit bundled `npm`, `npx`, and `corepack`. `pnpm server` is removed.
Package scripts named `clean`, `setup`, `deploy`, or `rebuild` take precedence;
use `pnpm pm <name>` to invoke the built-in command.
## Dependency builds and permissions
Dependency install scripts are blocked by default in pnpm 10.0. pnpm 11 removes
`onlyBuiltDependencies`, `onlyBuiltDependenciesFile`, `neverBuiltDependencies`,
`ignoredBuiltDependencies`, and `ignoreDepScripts`; migrate them to `allowBuilds`.
```yaml
allowBuilds:
esbuild: true
core-js: false
nx@21.6.4 || 21.6.5: true
```
pnpm 11 defaults `strictDepBuilds` to `true`. Named approvals and denials can be
non-interactive, and `--all` approves every pending dependency build:
```sh
pnpm approve-builds esbuild '!core-js'
pnpm approve-builds --all
```
In 12.11.0, `permissions`' `build` capability takes precedence over `allowBuilds`.
`pnpm permissions` lists grants, denials, and pending approvals. `pnpm approve`
reviews builds and skills together; `pnpm approve-builds` writes to `permissions`
when present and otherwise to `allowBuilds`.
In 12.24.0, `pnpm approve <pkg>` prompts for permissions when no request is pending;
use `permissions` or `pnpm approve-builds` for advance build grants in CI.
Pending approvals requiring a prompt fail without a terminal or in CI unless
package arguments or `--all` are supplied in 11.28.13/12.22.0 for
`approve-builds`, and in 12.22.0 for `approve`.
From 12.12.0, `allowBuilds` entries set to `false` still deny builds when
`dangerouslyAllowAllBuilds` is enabled. Git-hosted artifacts require a repository
approval even when their package name is approved. In 12.24.0, `R` in the
approval prompt grants a Git repository across commits.
In 12.22.0, `pnpm approve-builds -g` and `pnpm add -g --allow-build` save decisions
under `globalPackagesConfig.permissions` in global `config.yaml`.
In 12.24.0, `pnpm approve -g` reviews global builds and skills.
## Supply-chain policy and registry configuration
pnpm 11 defaults `minimumReleaseAge` to 1440 minutes and `blockExoticSubdeps` to
`true`. Exotic-source blocking applies to transitive Git URLs and direct HTTPS
tarballs; direct dependencies can still use them.
In 12.3, explicitly configuring `minimumReleaseAge` makes
`minimumReleaseAgeStrict` default to `true`; the built-in cutoff uses non-strict mode.
`minimumReleaseAgeExclude` supports package names, patterns, and exact versions.
`trustPolicy: no-downgrade` rejects weaker trust evidence. `trustLockfile: true`
skips release-age and trust-policy rechecks for loaded lockfile entries; its
default is `false`. Offline verification needs cached registry metadata and
otherwise fails with `ERR_PNPM_NO_OFFLINE_META`.
In 12.19.0 and 11.28.12, registry URLs in repository YAML or project `.npmrc`
must not contain `${VAR}`. Workspace proxy, `pnprServer`, and `userAgent`
placeholders are skipped with a warning. URL-scoped credentials can come from
`pnpm_config_//…` or `npm_config_//…`; the former wins for the same key.
From 10.34.0, tarball integrity mismatches stop non-frozen installs too, including
`--force`, `--fix-lockfile`, and updates. To refresh locked checksums from the registry:
```sh
pnpm install --update-checksums
```
pnpm warns when that command accepts a mismatch. Registry-revision support is
removed in 11.28.7; revision guidance for pnpm 12 and pnpr is separate in the reference.
## Installation, stores, and deployment
In 11.28.13 and 12.22.0, `pnpm ci` validates the lockfile against the manifest
before deleting modules. `ci` and `clean` honor workspace filters. External
`modulesDir` contents stay intact, and a symlinked `node_modules` is unlinked
without changing its target.
For projects, `virtualStoreType: global` in workspace YAML selects the shared
virtual store; `project` is the default. This setting takes precedence over
`enableGlobalVirtualStore`.
`frozenStore` needs an already populated store and required build outputs, is
incompatible with `--force` and a configured pnpr server; the installation
reference gives the Node.js requirements for the read-only-store workflow.
The experimental `loaded` linker uses `nodeLinker.type: loaded`. In 12.11.0,
it rejects Node.js outside `^24.18.0 || >=26.2.0`. Use `nodeLinker.excluded` for
packages whose computed imports escape detection; `sideEffectsCache.exclude`
excludes matched packages from local and remote build-cache reads and writes.
In 12.19.0, `lockfile.format: v13` opts into the experimental JSON-like YAML
format. In 12.22.0, run `pnpm install` to rewrite an earlier v13 lockfile.
Deploy supports linked workspace packages with injection disabled from 12.2.
In 11.28.3 and 12.8.2, deploy stops inheriting the root package-manager pin;
declare a required pin in the deployed project's own manifest.
In 12.19.0 and 11.28.12, `pnpm deploy --offline --trust-lockfile` uses source
lockfile versions with a populated store when registry metadata is unavailable.
## Catalogs, overrides, and patches
Use `pnpm add --save-catalog` or `--save-catalog-name=<name>` to save catalog
dependencies. In 12.24.0, grouped configuration is available alongside flat settings:
```yaml
overrides:
rules:
lodash: ^4.17.21
unused: warn
catalog:
entries:
react: ^19.0.0
unused: prune
mode: prefer
```
In 11.28.13 and 12.22.0, narrower matching override ranges win regardless of
declaration order. In 12.17.0, suffix selectors with `:prod`, `:optional`, or
`:peer` to restrict the dependency group.
Exact-version patches take precedence over ranges, then package-name-only patches.
Keep ranges for one package disjoint. In 12.25.0, `pnpm patch-commit` captures
binary edits and `patchedDependencies` restores them byte for byte.
## Scripts, tasks, and runtimes
pnpm 11 defaults `verifyDepsBeforeRun` to `install`. In 12.25.0, a missing
lockfile counts as stale dependencies for `run` and `exec`: `install` restores
it before the command, while `error` refuses to run.
Workspace task `dependsOn` uses `^build` for dependencies' build tasks and bare
`build` for the current project. A missing task entry implies `['^<task>']`;
an entry without `dependsOn` has no prerequisites. Preview with
`pnpm -r run --dry-run --json test`.
`pnpm pipeline [name]` reads workspace `pipelines`, installs with a frozen
lockfile, and runs affected projects' task graphs, continuing after task failures.
Tasks can declare `inputs`, `outputs`, `env`, and `cache`. In 12.22.0, `inputs: []`
hashes no files, `+` globs can include ignored and outside-project workspace files,
and `!` globs exclude matches.
With `onFail: download`, project `devEngines.runtime` resolution records an exact
version and checksum in the lockfile. `pnpm runtime set` writes `devEngines.runtime`
by default; `--save-prod` writes `engines.runtime`. In 12.25.0, `pnpm runtime unset`
removes runtimes provisioned with `pnpm runtime set`.
## Python, Cargo, audits, and releases
Enable `python.enabled` or `cargo.enabled` to install those ecosystems alongside
npm dependencies. Add packages with `pnpm add pypi:requests` or `pnpm add crate:serde`.
Python uses `pyproject.toml`, `pylock.toml`, and a managed `.venv`. pnpm can build
a source distribution when the index has no compatible wheel and `allowBuilds`
approves `pkg:pypi/<distribution>`. With Cargo enabled, pnpm installs the
toolchain pinned in `rust-toolchain.toml`.
In 12.25.1, pnpm-managed rustup for a global crate defaults to `stable`; add an
existing global crate again to apply the fix. In 12.25.0, `pnpm update --latest rust`
selects the Rust toolchain pin, while `pnpm update --latest '!rust'` excludes it.
`pnpm audit signatures` verifies registry signatures against locked integrity
in 11.28.5 and 12.10.0. In 12.24.0, `pnpm audit deprecations` and `pnpm audit engines`
report deprecated or incompatible installed packages and exit 1 when found.
`pnpm change` records release intents, `pnpm change status` previews a plan,
and `pnpm version -r` applies it. Recursive versioning propagates bumps through
`workspace:` dependencies and supports filters and dry runs. `pnpm change check`
validates release bands, fixed groups, and pending intent package names.