Commit Graph
34 Commits
Author SHA1 Message Date
Zoltan Kochan de561a55fa fix: prefer .pnpmfile.mjs by default (#10683)
* fix: prefer .pnpmfile.mjs by default

* fix: handle ERR_MODULE_NOT_FOUND for missing optional .pnpmfile.mjs

Node's dynamic import() throws ERR_MODULE_NOT_FOUND (not MODULE_NOT_FOUND
like require()) when a file doesn't exist. This caused a hard error when
tryLoadDefaultPnpmfile was enabled and .pnpmfile.mjs was absent.

* fix: load only .pnpmfile.mjs when it exists, not both .mjs and .cjs

When both .pnpmfile.mjs and .pnpmfile.cjs exist, only the .mjs file
is now loaded. Previously both were loaded and their hooks combined.
Also adds .mjs support for config dependency plugins.
2026-03-01 17:00:33 +01:00
Ryo Matsukawa 3ed41f4811 fix: shamefullyHoist set via updateConfig in .pnpmfile.cjs (#10519)
* fix: `shamefullyHoist` set via `updateConfig` in `.pnpmfile.cjs`

* refactor: consolidate derived config processing to cli-utils

Move shamefullyHoist → publicHoistPattern conversion from
config/config to cli-utils/getConfig.ts as suggested in review.

* test(config): update tests for derived config processing move

* refactor: move applyDerivedConfig to cli-utils

* refactor: move applyDerivedConfig to cli-utils

* test: use unit test for hoist: false in cli-utils

* revert: not needed changes

close #10271
2026-02-05 22:45:20 +01:00
Johan Quan Vo cc1b8e310a fix: use tarball URL returned in package metadata (#10431)
close #10254
2026-01-16 17:31:04 +01:00
Zoltan Kochan a8fe2d5298 feat!: remove the server command (#10463) 2026-01-15 11:32:07 +01:00
Zoltan Kochan e146e988ea feat: loading ESM pnpmfiles (#9730) 2025-10-10 09:50:21 +02:00
Zoltan Kochan e792927841 feat: support finder functions for performing complex searches with list and why commands (#9946) 2025-09-12 11:46:32 +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
Zoltan Kochan 3ebc0ce8b3 feat: scoped pnpm plugin config dependencies (#9824)
close #9780
2025-08-04 10:57:59 +02:00
Zoltan Kochan 7ad0bc3540 fix: run user pnpmfiles after plugin pnpmfiles (#9732) 2025-07-09 12:02:37 +02:00
Zoltan Kochan 295db51ef9 fix: the default pnpmfile should only be loaded if the pnpmfile settings is not set (#9731) 2025-07-09 11:00:52 +02:00
Zoltan Kochan e2253105d0 feat: loading pnpmfiles automatically from plugins (#9729) 2025-07-08 22:00:37 +02:00
Zoltan Kochan cf630a8e84 feat: allow to set multiple pnpmfiles (#9702) 2025-07-08 14:54:07 +02:00
Zoltan Kochan 1413c25435 feat: config update hook (#9325) 2025-03-31 08:08:32 +02:00
Zoltan Kochan 26b065c193 feat: automatically switch to the right pnpm version (#8363)
close #8360
2024-08-06 21:59:43 +02:00
Munif Tanjim 98c8bd69cb fix: print warnings to stderr (#8342) 2024-08-04 01:53:52 +02:00
Zoltan Kochan 64e2e4f86f refactor: add a function for corepack context detection 2024-08-02 23:02:15 +02:00
Simon He b6acfcf8d1 refactor(cli): conditional branch (#8290) 2024-07-08 16:03:17 +02:00
Khải 1b03682903 feat(dlx): read auth from local .npmrc (#8207)
close #7996
2024-06-25 17:51:43 +02:00
Zoltan Kochan b7ca13f7f2 fix: don't fail if the pnpm version doesn't match the one in the packageManager field (#8166)
close #8087
2024-06-05 14:38:21 +02:00
Zoltan Kochan a80b539c36 fix: print a hint about the package-manager-strict setting (#7960)
close #7956
2024-04-18 13:18:30 +02:00
Khải 1effaf012d refactor(cli): return type annotations (#7920) 2024-04-13 22:36:31 +02:00
Zoltan Kochan 934bcbd994 fix: don't check the package manager field, when executed by corepack
close #7849
ref #7853
2024-04-04 19:03:02 +02:00
Zoltan Kochan 15dbb637e4 fix: don't check the package manager field, when executed by corepack (#7853)
close #7849
2024-04-03 12:28:59 +02:00
BlueGreenMagickandZoltan Kochan 8c5fe4febe fix: packageManager field can contain various values (#7734)
* fix: fix packageManager field not working with prerelease version

* fix: remove hash from packageManager reference

* test: install should not fail for packageManager field with hash

* fix: packageManager field may contain URL instead of semver

corepack uses `URL.canParse()` to check if a given value is a URL or semver,
which was only added in recent Node versions and
is not supported by all node versions `"node" >= "18.12"` that pnpm supports.

So instead, we check if the value contains ':'
as it may not appear on semver, while it must appear on URL.

* test: install should not fail for packageManager field with url

* test: checking prerelease versions in package-is-installable

* fix: typo

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2024-03-07 02:00:03 +01:00
Zoltan Kochan 3477ee5ee8 feat!: check the packageManager field (#7635)
* feat!: check the packageManager field

* test: fix

* refactor: update error message to match what corepack prints

* feat: add pm-strict option

* refactor: pm-strict=>package-manager-strict

* fix: remove packageManager field from package.json on publish
2024-02-11 01:07:23 +01:00
chlorine ac71ce108c fix: the warning should not be printed when --json is specified (#7522)
close #7514
2024-01-13 14:33:37 +01:00
Nacho AldamaandZoltan Kochan 43ce9e4a6a feat: add support to install different architectures (#7214)
close #5965

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2023-10-24 15:50:40 +03:00
Josh Goldberg ✨andZoltan Kochan ee429b300b feat: expanded missing command error, including 'did you mean' (#6496)
close #6492

Co-authored-by: Zoltan Kochan <z@kochan.io>
2023-05-15 03:22:26 +03:00
Zoltan Kochan ee61ca4cb7 style: update eslint (#6236) 2023-03-18 14:57:29 +02:00
await-ovo 7d64d757bb fix: add report summary skipped status when script is missing (#6139) 2023-02-27 18:28:01 +02:00
await-ovo 0377d93678 feat: add --report-summary option for pnpm exec and pnpm run (#6098)
close #6008
2023-02-20 03:36:35 +02:00
Zoltan Kochan 583e3954be fix: remove suppressImplicitAnyIndexErrors from typescript settings (#5991) 2023-01-28 18:19:26 +02:00
Zoltan Kochan 4ca53b0b50 refactor: group projects in different subdirectories (#5659) 2022-11-20 01:35:22 +02:00