Type object
File match pnpm-workspace.yaml
Schema URL https://catalog.lintel.tools/schemas/schemastore/pnpm-workspace-pnpm-workspace-yaml/latest.json
Source https://www.schemastore.org/pnpm-workspace.json

Validate with Lintel

npx @lintel/lintel check
Type: object

JSON schema for pnpm-workspace.yaml files

Properties

packages string[]

Workspace package paths. Glob patterns are supported

uniqueItems=true
catalog Record<string, string>

Dependencies are specified with a simple hash of package name to version range. The version range is a string which has one or more space-separated descriptors. Dependencies can also be identified with a tarball or git URL.

catalogs Record<string, object>

Define arbitrarily named catalogs

catalogMode string

Controlling if and how dependencies are added to the default catalog

cleanupUnusedCatalogs boolean

When set to true, pnpm will remove unused catalog entries during installation.

onlyBuiltDependencies string[]

A list of package names that are allowed to be executed during installation.

overrides object

Used to override any dependency in the dependency graph.

packageExtensions object

Used to extend the existing package definitions with additional information.

peerDependencyRules object
3 nested properties
ignoreMissing string[]

pnpm will not print warnings about missing peer dependencies from this list.

allowedVersions object

Unmet peer dependency warnings will not be printed for peer dependencies of the specified range.

allowAny string[]

Any peer dependency matching the pattern will be resolved from any version, regardless of the range specified in "peerDependencies".

neverBuiltDependencies string[]

A list of dependencies to run builds for.

dangerouslyAllowAllBuilds boolean

If set to true, all build scripts (e.g. preinstall, install, postinstall) from dependencies will run automatically, without requiring approval.

onlyBuiltDependenciesFile string

Specifies a JSON file that lists the only packages permitted to run installation scripts during the pnpm install process.

ignoredBuiltDependencies string[]

A list of package names that should not be built during installation.

allowedDeprecatedVersions Record<string, string>

A list of deprecated versions that the warnings are suppressed.

patchedDependencies Record<string, string>

A list of dependencies that are patched.

allowUnusedPatches boolean

When true, installation won't fail if some of the patches from the "patchedDependencies" field were not applied. (Previously named "allowNonAppliedPatches")

allowNonAppliedPatches boolean

When true, installation won't fail if some of the patches from the "patchedDependencies" field were not applied.

ignorePatchFailures boolean

Default is undefined. Errors out when a patch with an exact version or version range fails. Ignores failures from name-only patches. When true, prints a warning instead of failing when any patch cannot be applied. When false, errors out for any patch failure.

updateConfig object
1 nested properties
ignoreDependencies string[]

A list of packages that should be ignored when running "pnpm outdated" or "pnpm update --latest".

configDependencies object

Config dependencies allow you to share and centralize configuration files, settings, and hooks across multiple projects. They are installed before all regular dependencies ('dependencies', 'devDependencies', 'optionalDependencies'), making them ideal for setting up custom hooks, patches, and catalog entries.

auditConfig object
2 nested properties
ignoreCves string[]

A list of CVE IDs that will be ignored by "pnpm audit".

ignoreGhsas string[]

A list of GHSA Codes that will be ignored by "pnpm audit".

requiredScripts string[]

A list of scripts that must exist in each project.

supportedArchitectures object

Specifies architectures for which you'd like to install optional dependencies, even if they don't match the architecture of the system running the install.

3 nested properties
os string[]
cpu string[]
libc string[]
ignoredOptionalDependencies string[]

A list of optional dependencies that the install should be skipped.

executionEnv object
1 nested properties
nodeVersion string

Specifies which exact Node.js version should be used for the project's runtime.

hoist boolean

When true, all dependencies are hoisted to node_modules/.pnpm/node_modules.

hoistWorkspacePackages boolean

When true, packages from the workspaces are symlinked to either <workspace_root>/node_modules/.pnpm/node_modules or to <workspace_root>/node_modules depending on other hoisting settings (hoistPattern and publicHoistPattern).

hoistPattern string[]

Tells pnpm which packages should be hoisted to node_modules/.pnpm/node_modules

publicHoistPattern string[]

Unlike hoistPattern, which hoists dependencies to a hidden modules directory inside the virtual store, publicHoistPattern hoists dependencies matching the pattern to the root modules directory.

shamefullyHoist boolean

By default, pnpm creates a semistrict node_modules, meaning dependencies have access to undeclared dependencies but modules outside of node_modules do not.

modulesDir string

The directory in which dependencies will be installed (instead of node_modules).

nodeLinker string

Defines what linker should be used for installing Node packages.

enableModulesDir boolean

When false, pnpm will not write any files to the modules directory (node_modules).

virtualStoreDir string

The directory with links to the store.

virtualStoreDirMaxLength number

Sets the maximum allowed length of directory names inside the virtual store directory (node_modules/.pnpm).

packageImportMethod string

Controls the way packages are imported from the store (if you want to disable symlinks inside node_modules, then you need to change the nodeLinker setting, not this one).

modulesCacheMaxAge number

The time in minutes after which orphan packages from the modules directory should be removed.

dlxCacheMaxAge number

The time in minutes after which dlx cache expires.

storeDir string

The location where all the packages are saved on the disk.

verifyStoreIntegrity boolean

By default, if a file in the store has been modified, the content of this file is checked before linking it to a project's node_modules.

strictStorePkgContentCheck boolean

Some registries allow the exact same content to be published under different package names and/or versions.

enableGlobalVirtualStore boolean

When enabled, node_modules contains only symlinks to a central virtual store, rather than to node_modules/.pnpm.

lockfile boolean

When set to false, pnpm won't read or generate a pnpm-lock.yaml file.

preferFrozenLockfile boolean

When set to true and the available pnpm-lock.yaml satisfies the package.json dependencies directive, a headless installation is performed.

lockfileIncludeTarballUrl boolean

Add the full URL to the package's tarball to every entry in pnpm-lock.yaml.

gitBranchLockfile boolean

When set to true, the generated lockfile name after installation will be named based on the current branch name to completely avoid merge conflicts.

mergeGitBranchLockfilesBranchPattern array | null

This configuration matches the current branch name to determine whether to merge all git branch lockfile files.

peersSuffixMaxLength number

Max length of the peer IDs suffix added to dependency keys in the lockfile. If the suffix is longer, it is replaced with a hash.

registry string

The base URL of the npm package registry (trailing slash included).

ca string

The Certificate Authority signing certificate that is trusted for SSL connections to the registry.

cafile string

A path to a file containing one or multiple Certificate Authority signing certificates.

cert string

A client certificate to pass when accessing the registry.

key string

A client key to pass when accessing the registry.

gitShallowHosts string[]

When fetching dependencies that are Git repositories, if the host is listed in this setting, pnpm will use shallow cloning to fetch only the needed commit, not all the history.

httpsProxy string

A proxy to use for outgoing HTTPS requests. If the HTTPS_PROXY, https_proxy, HTTP_PROXY or http_proxy environment variables are set, their values will be used instead.

proxy string

A proxy to use for outgoing http requests. If the HTTP_PROXY or http_proxy environment variables are set, proxy settings will be honored by the underlying request library.

localAddress string

The IP address of the local interface to use when making connections to the npm registry.

maxsockets number

The maximum number of connections to use per origin (protocol/host/port combination).

noproxy string

A comma-separated string of domain extensions that a proxy should not be used for.

strictSsl boolean

Whether or not to do SSL key validation when making requests to the registry via HTTPS.

networkConcurrency number

Controls the maximum number of HTTP(S) requests to process simultaneously.

fetchRetries number

How many times to retry if pnpm fails to fetch from the registry.

fetchRetryFactor number

The exponential factor for retry backoff.

fetchRetryMintimeout number

The minimum (base) timeout for retrying requests.

fetchRetryMaxtimeout number

The maximum fallback timeout to ensure the retry factor does not make requests too long.

fetchTimeout number

The maximum amount of time to wait for HTTP requests to complete.

autoInstallPeers boolean

When true, any missing non-optional peer dependencies are automatically installed.

dedupePeerDependents boolean

When this setting is set to true, packages with peer dependencies will be deduplicated after peers resolution.

strictPeerDependencies boolean

If this is enabled, commands will fail if there is a missing or invalid peer dependency in the tree.

resolvePeersFromWorkspaceRoot boolean

When enabled, dependencies of the root workspace project are used to resolve peer dependencies of any projects in the workspace.

color string

Controls colors in the output.

loglevel string

Any logs at or higher than the given level will be shown.

reporter string

Allows you to customize the output style of the logs. https://pnpm.io/cli/install#--reportername

Values: "silent" "default" "append-only" "ndjson"
useBetaCli boolean

Experimental option that enables beta features of the CLI.

recursiveInstall boolean

If this is enabled, the primary behaviour of pnpm install becomes that of pnpm install -r, meaning the install is performed on all workspace or subdirectory packages.

engineStrict boolean

If this is enabled, pnpm will not install any package that claims to not be compatible with the current Node version.

npmPath string

The location of the npm binary that pnpm uses for some actions, like publishing.

packageManagerStrict boolean

If this setting is disabled, pnpm will not fail if a different package manager is specified in the packageManager field of package.json. When enabled, only the package name is checked (since pnpm v9.2.0), so you can still run any version of pnpm regardless of the version specified in the packageManager field.

packageManagerStrictVersion boolean

When enabled, pnpm will fail if its version doesn't exactly match the version specified in the packageManager field of package.json.

managePackageManagerVersions boolean

When enabled, pnpm will automatically download and run the version of pnpm specified in the packageManager field of package.json.

ignoreScripts boolean

Do not execute any scripts defined in the project package.json and its dependencies.

ignoreDepScripts boolean

Do not execute any scripts of the installed packages. Scripts of the projects are executed.

childConcurrency number

The maximum number of child processes to allocate simultaneously to build node_modules.

sideEffectsCache boolean

Use and cache the results of (pre/post)install hooks.

sideEffectsCacheReadonly boolean

Only use the side effects cache if present, do not create it for new packages.

unsafePerm boolean

Set to true to enable UID/GID switching when running package scripts. If set explicitly to false, then installing as a non-root user will fail.

nodeOptions string

Options to pass through to Node.js via the NODE_OPTIONS environment variable.

verifyDepsBeforeRun string | boolean

This setting allows the checking of the state of dependencies before running scripts.

strictDepBuilds boolean

When strictDepBuilds is enabled, the installation will exit with a non-zero exit code if any dependencies have unreviewed build scripts (aka postinstall scripts).

useNodeVersion string

Specifies which exact Node.js version should be used for the project's runtime.

nodeVersion string

The Node.js version to use when checking a package's engines setting.

linkWorkspacePackages boolean | string

If this is enabled, locally available packages are linked to node_modules instead of being downloaded from the registry.

injectWorkspacePackages boolean

Enables hard-linking of all local workspace dependencies instead of symlinking them.

syncInjectedDepsAfterScripts string[]

Injected workspace dependencies are collections of hardlinks, which don't add or remove the files when their sources change.

uniqueItems=true
preferWorkspacePackages boolean

If this is enabled, local packages from the workspace are preferred over packages from the registry, even if there is a newer version of the package in the registry.

sharedWorkspaceLockfile boolean

If this is enabled, pnpm creates a single pnpm-lock.yaml file in the root of the workspace.

saveWorkspaceProtocol boolean | string

This setting controls how dependencies that are linked from the workspace are added to package.json.

includeWorkspaceRoot boolean

When executing commands recursively in a workspace, execute them on the root workspace project as well.

ignoreWorkspaceCycles boolean

When set to true, no workspace cycle warnings will be printed.

ignoreWorkspaceRootCheck boolean

Adding a new dependency to the root workspace package fails, unless the --ignore-workspace-root-check or -w flag is used.

disallowWorkspaceCycles boolean

When set to true, installation will fail if the workspace has cycles.

workspaceConcurrency number

Set the maximum number of tasks to run simultaneously. For unlimited concurrency use Infinity. You can set the value to <= 0 and it will use amount of CPU cores of the host minus the absolute value of the provided number as: max(1, (number of cores) - abs(workspaceConcurrency)).

Default: 4
failIfNoMatch boolean

If true, pnpm will fail if no packages match the filter

Default: false
forceLegacyDeploy boolean

By default, pnpm deploy will try creating a dedicated lockfile from a shared lockfile for deployment. If this setting is set to true, the legacy deploy behavior will be used.

savePrefix string

Configure how versions of packages installed to a package.json file get prefixed.

tag string

If you pnpm add a package and you don't provide a specific version, then it will install the package at the version registered under the tag from this setting.

globalDir string

Specify a custom directory to store global packages.

globalBinDir string

Allows to set the target directory for the bin files of globally installed packages.

stateDir string

The location where all the packages are saved on the disk.

cacheDir string

The location of the cache (package metadata and dlx).

useStderr boolean

When true, all the output is written to stderr.

updateNotifier boolean

When true, pnpm will check for updates to the installed packages and notify the user.

preferSymlinkedExecutables boolean

Create symlinks to executables in node_modules/.bin instead of command shims. This setting is ignored on Windows, where only command shims work.

ignoreCompatibilityDb boolean

During installation the dependencies of some packages are automatically patched. If you want to disable this, set this config to false.

resolutionMode string

Determines how pnpm resolves dependencies, See https://pnpm.io/settings#resolutionmode

registrySupportsTimeField boolean

Set this to true if the registry that you are using returns the "time" field in the abbreviated metadata.

extendNodePath boolean

When false, the NODE_PATH environment variable is not set in the command shims.

deployAllFiles boolean

When deploying a package or installing a local package, all files of the package are copied.

dedupeDirectDeps boolean

When set to true, dependencies that are already symlinked to the root node_modules directory of the workspace will not be symlinked to subproject node_modules directories.

dedupeInjectedDeps boolean

When this setting is enabled, dependencies that are injected will be symlinked from the workspace whenever possible.

optimisticRepeatInstall boolean

When enabled, a fast check will be performed before proceeding to installation. This way a repeat install or an install on a project with everything up-to-date becomes a lot faster.

gitChecks boolean

Check if current branch is your publish branch, clean, and up-to-date with remote.

publishBranch string

The primary branch of the repository which is used for publishing the latest changes.

pnpmfile string

The location of the local pnpmfile.

globalPnpmfile string

The location of a global pnpmfile. A global pnpmfile is used by all projects during installation.

ignorePnpmfile boolean

.pnpmfile.cjs will be ignored. Useful together with --ignore-scripts when you want to make sure that no script gets executed during install.

patchesDir string

The generated patch file will be saved to this directory.

enablePrePostScripts boolean

When true, pnpm will run any pre/post scripts automatically.

scriptShell string

The shell to use for scripts run with the pnpm run command.

shellEmulator boolean

When true, pnpm will use a JavaScript implementation of a bash-like shell to execute scripts.

saveExact boolean

Saved dependencies will be configured with an exact version rather than using pnpm's default semver range operator.

minimumReleaseAge number

minimumReleaseAge defines the minimum number of minutes that must pass after a version is published before pnpm will install it. This applies to all dependencies, including transitive ones.

minimumReleaseAgeExclude string[]

If you set minimumReleaseAge but need certain dependencies to always install the newest version immediately, you can list them under minimumReleaseAgeExclude. The exclusion works by package name and applies to all versions of that package.

uniqueItems=true
preferOffline boolean

Bypass staleness checks for cached data. Missing data will still be requested from the server.

trustPolicy string

When set to no-downgrade, pnpm will fail if a package's trust level has decreased compared to previous releases. For example, if a package was previously published by a trusted publisher but now only has provenance or no trust evidence, installation will fail. This helps prevent installing potentially compromised versions.

trustPolicyExclude string[]

You can now list one or more specific packages or versions that pnpm should allow to install, even if those packages don't satisfy the trust policy requirement.

uniqueItems=true
allowBuilds object

A map of package matchers to explicitly allow (true) or disallow (false) script execution. This field replaces onlyBuiltDependencies and ignoredBuiltDependencies (which are also deprecated by this new setting), providing a single source of truth.

blockExoticSubdeps boolean

When set to true, it prevents the resolution of exotic protocols (like git+ssh: or direct https: tarballs) in transitive dependencies. Only direct dependencies are allowed to use exotic sources.

trustPolicyIgnoreAfter number

Allows ignoring the trust policy check for packages published more than the specified number of minutes ago. This is useful when enabling strict trust policies, as it allows older versions of packages (which may lack a process for publishing with signatures or provenance) to be installed without manual exclusion, assuming they are safe due to their age.

auditLevel string

Controls the level of issues reported by pnpm audit. When set to 'low', all vulnerabilities are reported. When set to 'moderate', 'high', or 'critical', only vulnerabilities with that severity or higher are reported.

dedupePeers boolean

When enabled, peer dependency suffixes use version-only identifiers (name@version) instead of full dep paths, eliminating nested suffixes like ([email protected]([email protected])). This dramatically reduces the number of package instances in projects with many recursive peer dependencies.

Definitions

dependency Record<string, string>

Dependencies are specified with a simple hash of package name to version range. The version range is a string which has one or more space-separated descriptors. Dependencies can also be identified with a tarball or git URL.

devDependency Record<string, string>

Specifies dependencies that are required for the development and testing of the project. These dependencies are not needed in the production environment.

optionalDependency Record<string, string>

Specifies dependencies that are optional for your project. These dependencies are attempted to be installed during the npm install process, but if they fail to install, the installation process will not fail.

peerDependency Record<string, string>

Specifies dependencies that are required by the package but are expected to be provided by the consumer of the package.

peerDependencyMeta Record<string, object>

When a user installs your package, warnings are emitted if packages specified in "peerDependencies" are not already installed. The "peerDependenciesMeta" field serves to provide more information on how your peer dependencies are utilized. Most commonly, it allows peer dependencies to be marked as optional. Metadata for this field is specified with a simple hash of the package name to a metadata object.

catalog Record<string, string>

Dependencies are specified with a simple hash of package name to version range. The version range is a string which has one or more space-separated descriptors. Dependencies can also be identified with a tarball or git URL.