Commit Graph

197 Commits

Author SHA1 Message Date
Zoltan Kochan
dee39ecb8a feat: support allowing the build of specific versions of dependencies (#10104)
close #10076
2025-10-21 12:38:16 +02:00
Zoltan Kochan
c5e895f657 fix: don't print a warning when --lockfile-only is used (#10044)
close #8320
2025-10-05 02:28:26 +02:00
Tom Jenkinson
2ebd45a7f2 fix: throw error if no TTY instead of terminating with 0 exit code (#9960)
close #9744
2025-09-12 12:07:01 +02:00
Zoltan Kochan
38e2599ecd feat: set minimumReleaseAge to delay new versions of dependencies from being installed (#9957)
close #9921
2025-09-11 17:25:11 +02:00
btea
05dd45ea82 perf: replace startsWith with strict equality (#9881) 2025-08-21 14:14:26 +02:00
Zoltan Kochan
facd7656e8 refactor: always use extensions in relative imports (#9878) 2025-08-19 15:25:11 +02:00
btea
8747b4e7f6 feat: add cleanupUnusedCatalogs config (#9793) 2025-08-14 12:26:51 +02:00
Brandon Cheng
98dd75a5d9 fix: re-resolve catalog entries when running pnpm dedupe (#9808)
* test: catalog is deduped on pnpm dedupe

* fix: re-resolve catalog entries when running `pnpm dedupe`
2025-07-30 11:47:27 +02:00
Zoltan Kochan
cf630a8e84 feat: allow to set multiple pnpmfiles (#9702) 2025-07-08 14:54:07 +02:00
Zoltan Kochan
cc6db888d6 fix: hoisting of dependencies after resolution stage (#9686)
close #9685
2025-06-24 11:51:18 +02:00
Zoltan Kochan
b982a0d6dc fix: hoisting with global virtual store (#9648) 2025-06-22 22:03:29 +02:00
Zoltan Kochan
b217bbb4a7 feat: add a new setting for telling pnpm if the env is CI (#9616)
This is an addition to https://github.com/pnpm/pnpm/pull/8190. The global virtual store isn't a good choice for CI. So, we disable it even if the setting sets `enableGlobalVirtualStore` to `true`.
2025-06-08 15:00:22 +02:00
Zoltan Kochan
b3898dbb1e fix: take into account the integrities of packages in when calculating the dependency graph hash (#9605)
* fix: take into account the integrities of packages in when calculating the dependency graph hash

* test: fix

* test: fix

* test: fix

* test: fix

* fix: include the package's integirty in the hash as well

* docs: add comment

* perf: hashing deps graph

* fix: deps graph hash

* refactor: calc graph hash

* test: fix

* refactor: calc graph hash

* refactor: rename uniquePkgId to fullPkgId

* docs: add changeset
2025-06-08 01:05:10 +02:00
Zoltan Kochan
b0ead519b3 feat: global virtual store (#8190)
close #1001
2025-06-03 18:18:58 +02:00
Brandon Cheng
099ac93e08 refactor: use Catalogs config type instead of CatalogSnapshots for updatedCatalogs (#9589)
* refactor: use Catalogs config type instead of CatalogSnapshots

* refactor: create catalogMetadata instead of manually patching snapshots
2025-06-01 23:53:04 +02:00
Zoltan Kochan
7cd0e712df fix: install exiting with 1 exit code and no error message (#9567)
close #9559
2025-05-22 15:26:51 +02:00
martinkors
046af72a96 feat: add new catalogMode setting (#9552)
* feat: add new `catalogMode` setting

Add new `catalogMode` setting for automatically adding new dependencies to
the default catalog.

Closes pnpm#8876, Closes pnpm#8308

* fix: catalogs don't only store semver ranges and versions

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2025-05-20 16:47:05 +02:00
Brandon Cheng
e7d0f6cdcf refactor: rename newCatalogs to updatedCatalogs (#9561) 2025-05-20 11:15:41 +02:00
Khải
93ac21ccd0 refactor: add types to installSome and installCase (#9539)
---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2025-05-15 11:16:22 +02:00
Khải
c8341cca57 feat: pnpm add option to add new entries to catalogs (#9484)
close #9425

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2025-05-14 18:32:05 +02:00
Zoltan Kochan
f0c3ed6781 fix: don't fail with strictPeerDependencies=true if the peerDependencyRules ignore the peer issues (#9505)
close #9449
close #8859
close #7978
close #8382
2025-05-09 11:38:56 +02:00
Zoltan Kochan
8a9f3a4835 refactor: rename pref to bare specifier (#9445) 2025-04-20 22:58:08 +02:00
Khải
5d7ba81f77 refactor: replace & with interface extends where possible (#9437) 2025-04-18 23:02:25 +02:00
Zoltan Kochan
5b73df1eb1 refactor: resolvers should calculate the specifiers that are saved into package.json (#9426)
* refactor: resolvers should return specifier templates

* refactor: updating workspace protocol specs in package.json

* refactor: move workspace selector calculation logic to npm-resolver

* refactor: move workspace selector calculation logic to npm-resolver

* refactor: calculating range in npm-resolver

* refactor: rename normalizedPref and specifierTemplate to specifier

* refactor: specifiers creation

* refactor: npm-resolver

* refactor: remove which-version-is-pinned package

* refactor: which version is pinned

* docs: add changesets

* refactor: implement suggestions

* refactor: revert regex usage
2025-04-18 17:48:03 +02:00
Zoltan Kochan
81f441cd3a refactor: updating specs in the manifest (#9410) 2025-04-13 21:44:35 +02:00
btea
bd94ce0753 fix: keep the ignoredBuilds field when installing different pkg (#9242)
* fix: keep the `ignoredBuilds` field when installing different dependencies

* fix: print warning about ignored builds

---------

close #9240

Co-authored-by: Zoltan Kochan <z@kochan.io>
2025-03-19 01:09:12 +01:00
Khải
5f7be645e4 feat(patching): version ranges and strict patches (#9236)
* feat: replace a config

This is a test commit to see if CI fails

* feat: `strictPatches`

* docs: future instruction

* feat: `strictPatches` → `allowPatchFailure`

* docs(changeset): correction

* test: getOptionsFromRootManifest

* fix: allowFailure

* feat: groupPatchedDependencies

* fix: update code after merge

* fix: star spec

* feat: error on invalid ranges

* fix: eslint

* docs: change task

* feat(patching): version ranges

* fix: `verifyPatches`

* refactor: move types to `@pnpm/patching.types`

* docs(changeset): add missing package

* refactor: move `verifyPatches` to `@pnpm/patching.config`

* test: fix

* feat: change error message of unused patches

* refactor: exact options into an interface

* test(patching): version range

* test(patching): allowPatchFailure

* docs: change wording

* docs: change wording

* test(patching): version range error

* test(patching): legacy behavior

* test: don't use star

* test(patching): strict versionless

* test: strictPatches

* chore(deps): `@pnpm/logger` must be peer

* docs: fix grammar

* refactor: rename `blank` to `all`

* refactor: use string

* refactor: use array for `PatchGroup.range`

* refactor: stop re-exporting `allPatchKeys`

* feat: re-export `PatchGroupRangeItem`

* refactor: move error creation into a class

* docs: replace "versionless" with "name-only"

* docs: coherent wordings

* test: exact version overrides range conflict

* test: tweak

* docs: consistent wordings

* docs: correct wordings

* refactor: rename `allowPatchFailure` to `ignorePatchFailures`

* feat: replace `strictPatches` with `ignorePatchFailures`

* docs: legacy behavior

* feat: introduce `allowUnusedPatches`

* docs(changeset): update

* docs: remove outdated comment

* docs: backward-compatibility
2025-03-13 12:13:06 +01:00
btea
adb236f1a1 refactor: improve regexp (#9203) 2025-03-02 13:17:09 +01:00
Brandon Cheng
41dada429b fix: catalog snapshots removed on filtered install with --fix-lockfile (#9152)
close #8639
2025-02-24 02:41:27 +01:00
Brandon Cheng
43681529cf refactor: make frozen install logic clearer (#9148)
* refactor: declare interface for `_install` function result

* refactor: create new function for attempting frozen install

* refactor: early return if frozen-like install is not possible

* refactor: early return in frozenInstall() for empty/missing lockfile

* refactor: return `null` from tryFrozenInstall() if attempt failed

* refactor: add comments to `isFrozenInstallPossible`

* refactor: move tryFrozenInstall out from _install

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2025-02-23 13:34:07 +01:00
Brandon Cheng
2d16f7a4a9 fix: stale catalog protocol reference on filtered install (#9126)
#8638
2025-02-22 13:22:36 +01:00
Zoltan Kochan
8fcc221394 feat: reading settings from pnpm-workspace.yaml (#9121)
Related discussion: https://github.com/orgs/pnpm/discussions/9037

close #9033
2025-02-22 02:10:43 +01:00
Zoltan Kochan
f6006f2b4b feat: add an option to fail on unapproved dependency builds (#9071) 2025-02-11 00:26:25 +01:00
Zoltan Kochan
371734043a fix: make the warning about blocked install scripts more prominent (#9067) 2025-02-09 01:34:18 +01:00
Zoltan Kochan
9843aedd76 fix: don't read from side-effects cache packages that aren't allowed to be built (#9047)
close #9042
2025-02-06 00:12:54 +01:00
btea
2b49ee77c7 fix: install dependencies execute preprepare and postprepare scripts (#8989)
* fix: install dependencies execute preprepare script

* chore: remove unnecessary code

* fix: postprepare should run

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2025-01-26 20:31:00 +01:00
btea
7a9473b237 fea: pnpm.ignoredBuiltDependencies for muting warnings about ignored dependency builds (#8958)
close #8935

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2025-01-12 02:17:44 +01:00
Zoltan Kochan
cc3bbc950d fix: don't load side-effects cache for packages that are not allowed to be built (#8901)
* fix: don't read ignored deps from side effects cache

* test: fix

* test: fix
2025-01-05 03:17:54 +01:00
Fotis Papadogeorgopoulos
c7eefdd082 fix: pnpm update --filter --latest should only change relevant packages and projects, with dedupe-peer-dependents=true (#8905)
* test(update): add failing tests for update with dedupe-peer-dependents=true

Relates to https://github.com/pnpm/pnpm/issues/8877

* fix: update --filter --latest should work with dedupe-peer-dependents

Fixes https://github.com/pnpm/pnpm/issues/8877, whereby
`update --filter --latest` with `dedupe-peer-dependents` would end up
updating all available dependencies for all projects.

* test(pnpm): more accurate dedupePeers filtered install case

* docs: add changeset for updateToLatest moving to projects/importers

* docs: add changesets for pnpm and plugin-commands-installation

* chore: fix tsc issue by removing unknown bound resolver property

This unknown property was accepted by tsc prior to adding updateToLatest
in toResovleImporter options, but now it was erroring out. This is
likely a tsc quirk about the shape of the object; regardless that
property is not defined, and should not be present.

* test: keep only pnpm/test/monorepo/dedupePeers.test.ts

There was duplicate coverage of the pnpm update --filter --latest
command between two tests, so this keeps only the one dedicated
to testing the dedupe-peer-dependents feature.

* chore: fix unused import error
2024-12-29 17:30:36 +01:00
Zoltan Kochan
4771813309 feat: store ignored dependencies list in modules state file (#8903) 2024-12-24 03:01:35 +01:00
Zoltan Kochan
512465c4ce refactor: remove allowBuild from options of resolveDependencies() (#8902) 2024-12-23 01:24:50 +01:00
martinkors
c0895e8b12 feat(add): pnpm add should use the default catalog (#8870)
close #8640
2024-12-16 02:10:24 +01:00
Zoltan Kochan
fb9e3b4ee0 feat!: drop lockfile v6 support 2024-12-15 15:38:20 +01:00
Zoltan Kochan
a76da0c53c feat!: remove conversion of lockfile v6 to v9 (#8866) 2024-12-15 14:39:19 +01:00
Zoltan Kochan
6483b646fe feat: a new setting for injecting workspace packages (#8836) 2024-12-05 17:37:15 +01:00
Zoltan Kochan
4b80c2c648 fix: do not fail if the active store directory was created by pnpm v9 (#8814)
* fix: do not fail if the active store directory was created by pnpm v9

* test: checkCompatibility
2024-11-28 08:55:19 +01:00
Jordan
9ea8fa457b fix: only validate modules directory if required (e.g. for install) (#8657) 2024-10-24 17:45:49 +02:00
Zoltan Kochan
477e0c1f74 feat!: the link command should add overrides (#8653) 2024-10-24 16:59:55 +02:00
Zoltan Kochan
b33f153b36 Merge branch 'main' into v10 2024-10-12 03:21:03 +02:00
Zoltan Kochan
a943fc9741 refactor: error message on out of date lockfile 2024-10-07 21:54:50 +02:00