pnpm 10.15.1 → 10.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/node_modules/.modules.yaml +10 -10
- package/dist/node_modules/.pnpm/lock.yaml +20 -20
- package/dist/node_modules/.pnpm-workspace-state-v1.json +1 -1
- package/dist/node_modules/ansi-regex/package.json +1 -1
- package/dist/node_modules/ansi-styles/index.js +3 -3
- package/dist/node_modules/ansi-styles/package.json +4 -4
- package/dist/node_modules/debug/package.json +1 -1
- package/dist/node_modules/strip-ansi/package.json +3 -1
- package/dist/pnpm.cjs +313 -88
- package/package.json +1 -1
|
@@ -16,14 +16,14 @@ hoistedLocations:
|
|
|
16
16
|
agent-base@7.1.4:
|
|
17
17
|
- node_modules/agent-base
|
|
18
18
|
ansi-regex@5.0.1:
|
|
19
|
-
- node_modules/string-width-cjs/node_modules/ansi-regex
|
|
20
19
|
- node_modules/wrap-ansi-cjs/node_modules/ansi-regex
|
|
20
|
+
- node_modules/string-width-cjs/node_modules/ansi-regex
|
|
21
21
|
- node_modules/strip-ansi-cjs/node_modules/ansi-regex
|
|
22
|
-
ansi-regex@6.2.
|
|
22
|
+
ansi-regex@6.2.2:
|
|
23
23
|
- node_modules/ansi-regex
|
|
24
24
|
ansi-styles@4.3.0:
|
|
25
25
|
- node_modules/wrap-ansi-cjs/node_modules/ansi-styles
|
|
26
|
-
ansi-styles@6.2.
|
|
26
|
+
ansi-styles@6.2.3:
|
|
27
27
|
- node_modules/ansi-styles
|
|
28
28
|
balanced-match@1.0.2:
|
|
29
29
|
- node_modules/balanced-match
|
|
@@ -39,13 +39,13 @@ hoistedLocations:
|
|
|
39
39
|
- node_modules/color-name
|
|
40
40
|
cross-spawn@7.0.6:
|
|
41
41
|
- node_modules/cross-spawn
|
|
42
|
-
debug@4.4.
|
|
42
|
+
debug@4.4.3:
|
|
43
43
|
- node_modules/debug
|
|
44
44
|
eastasianwidth@0.2.0:
|
|
45
45
|
- node_modules/eastasianwidth
|
|
46
46
|
emoji-regex@8.0.0:
|
|
47
|
-
- node_modules/string-width-cjs/node_modules/emoji-regex
|
|
48
47
|
- node_modules/wrap-ansi-cjs/node_modules/emoji-regex
|
|
48
|
+
- node_modules/string-width-cjs/node_modules/emoji-regex
|
|
49
49
|
emoji-regex@9.2.2:
|
|
50
50
|
- node_modules/emoji-regex
|
|
51
51
|
encoding@0.1.13:
|
|
@@ -101,8 +101,8 @@ hoistedLocations:
|
|
|
101
101
|
minipass-sized@1.0.3:
|
|
102
102
|
- node_modules/minipass-sized
|
|
103
103
|
minipass@3.3.6:
|
|
104
|
-
- node_modules/minipass-flush/node_modules/minipass
|
|
105
104
|
- node_modules/minipass-pipeline/node_modules/minipass
|
|
105
|
+
- node_modules/minipass-flush/node_modules/minipass
|
|
106
106
|
- node_modules/minipass-sized/node_modules/minipass
|
|
107
107
|
minipass@7.1.2:
|
|
108
108
|
- node_modules/minipass
|
|
@@ -156,10 +156,10 @@ hoistedLocations:
|
|
|
156
156
|
string-width@5.1.2:
|
|
157
157
|
- node_modules/string-width
|
|
158
158
|
strip-ansi@6.0.1:
|
|
159
|
-
- node_modules/string-width-cjs/node_modules/strip-ansi
|
|
160
159
|
- node_modules/wrap-ansi-cjs/node_modules/strip-ansi
|
|
160
|
+
- node_modules/string-width-cjs/node_modules/strip-ansi
|
|
161
161
|
- node_modules/strip-ansi-cjs
|
|
162
|
-
strip-ansi@7.1.
|
|
162
|
+
strip-ansi@7.1.2:
|
|
163
163
|
- node_modules/strip-ansi
|
|
164
164
|
tar@7.4.3:
|
|
165
165
|
- node_modules/tar
|
|
@@ -178,8 +178,8 @@ hoistedLocations:
|
|
|
178
178
|
wrap-ansi@8.1.0:
|
|
179
179
|
- node_modules/wrap-ansi
|
|
180
180
|
yallist@4.0.0:
|
|
181
|
-
- node_modules/minipass-flush/node_modules/yallist
|
|
182
181
|
- node_modules/minipass-pipeline/node_modules/yallist
|
|
182
|
+
- node_modules/minipass-flush/node_modules/yallist
|
|
183
183
|
- node_modules/minipass-sized/node_modules/yallist
|
|
184
184
|
yallist@5.0.0:
|
|
185
185
|
- node_modules/yallist
|
|
@@ -192,7 +192,7 @@ layoutVersion: 5
|
|
|
192
192
|
nodeLinker: hoisted
|
|
193
193
|
packageManager: pnpm@10.15.0
|
|
194
194
|
pendingBuilds: []
|
|
195
|
-
prunedAt:
|
|
195
|
+
prunedAt: Sat, 13 Sep 2025 17:42:21 GMT
|
|
196
196
|
publicHoistPattern: []
|
|
197
197
|
registries:
|
|
198
198
|
'@jsr': https://npm.jsr.io/
|
|
@@ -80,16 +80,16 @@ packages:
|
|
|
80
80
|
resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==}
|
|
81
81
|
engines: {node: '>=8'}
|
|
82
82
|
|
|
83
|
-
ansi-regex@6.2.
|
|
84
|
-
resolution: {integrity: sha512-
|
|
83
|
+
ansi-regex@6.2.2:
|
|
84
|
+
resolution: {integrity: sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==}
|
|
85
85
|
engines: {node: '>=12'}
|
|
86
86
|
|
|
87
87
|
ansi-styles@4.3.0:
|
|
88
88
|
resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==}
|
|
89
89
|
engines: {node: '>=8'}
|
|
90
90
|
|
|
91
|
-
ansi-styles@6.2.
|
|
92
|
-
resolution: {integrity: sha512-
|
|
91
|
+
ansi-styles@6.2.3:
|
|
92
|
+
resolution: {integrity: sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg==}
|
|
93
93
|
engines: {node: '>=12'}
|
|
94
94
|
|
|
95
95
|
balanced-match@1.0.2:
|
|
@@ -117,8 +117,8 @@ packages:
|
|
|
117
117
|
resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==}
|
|
118
118
|
engines: {node: '>= 8'}
|
|
119
119
|
|
|
120
|
-
debug@4.4.
|
|
121
|
-
resolution: {integrity: sha512-
|
|
120
|
+
debug@4.4.3:
|
|
121
|
+
resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==}
|
|
122
122
|
engines: {node: '>=6.0'}
|
|
123
123
|
peerDependencies:
|
|
124
124
|
supports-color: '*'
|
|
@@ -340,8 +340,8 @@ packages:
|
|
|
340
340
|
resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==}
|
|
341
341
|
engines: {node: '>=8'}
|
|
342
342
|
|
|
343
|
-
strip-ansi@7.1.
|
|
344
|
-
resolution: {integrity: sha512-
|
|
343
|
+
strip-ansi@7.1.2:
|
|
344
|
+
resolution: {integrity: sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA==}
|
|
345
345
|
engines: {node: '>=12'}
|
|
346
346
|
|
|
347
347
|
tar@7.4.3:
|
|
@@ -390,7 +390,7 @@ snapshots:
|
|
|
390
390
|
dependencies:
|
|
391
391
|
string-width: 5.1.2
|
|
392
392
|
string-width-cjs: string-width@4.2.3
|
|
393
|
-
strip-ansi: 7.1.
|
|
393
|
+
strip-ansi: 7.1.2
|
|
394
394
|
strip-ansi-cjs: strip-ansi@6.0.1
|
|
395
395
|
wrap-ansi: 8.1.0
|
|
396
396
|
wrap-ansi-cjs: wrap-ansi@7.0.0
|
|
@@ -429,7 +429,7 @@ snapshots:
|
|
|
429
429
|
ansi-regex@5.0.1:
|
|
430
430
|
optional: true
|
|
431
431
|
|
|
432
|
-
ansi-regex@6.2.
|
|
432
|
+
ansi-regex@6.2.2:
|
|
433
433
|
optional: true
|
|
434
434
|
|
|
435
435
|
ansi-styles@4.3.0:
|
|
@@ -437,7 +437,7 @@ snapshots:
|
|
|
437
437
|
color-convert: 2.0.1
|
|
438
438
|
optional: true
|
|
439
439
|
|
|
440
|
-
ansi-styles@6.2.
|
|
440
|
+
ansi-styles@6.2.3:
|
|
441
441
|
optional: true
|
|
442
442
|
|
|
443
443
|
balanced-match@1.0.2:
|
|
@@ -482,7 +482,7 @@ snapshots:
|
|
|
482
482
|
which: 2.0.2
|
|
483
483
|
optional: true
|
|
484
484
|
|
|
485
|
-
debug@4.4.
|
|
485
|
+
debug@4.4.3:
|
|
486
486
|
dependencies:
|
|
487
487
|
ms: 2.1.3
|
|
488
488
|
optional: true
|
|
@@ -540,7 +540,7 @@ snapshots:
|
|
|
540
540
|
http-proxy-agent@7.0.2:
|
|
541
541
|
dependencies:
|
|
542
542
|
agent-base: 7.1.4
|
|
543
|
-
debug: 4.4.
|
|
543
|
+
debug: 4.4.3
|
|
544
544
|
transitivePeerDependencies:
|
|
545
545
|
- supports-color
|
|
546
546
|
optional: true
|
|
@@ -548,7 +548,7 @@ snapshots:
|
|
|
548
548
|
https-proxy-agent@7.0.6:
|
|
549
549
|
dependencies:
|
|
550
550
|
agent-base: 7.1.4
|
|
551
|
-
debug: 4.4.
|
|
551
|
+
debug: 4.4.3
|
|
552
552
|
transitivePeerDependencies:
|
|
553
553
|
- supports-color
|
|
554
554
|
optional: true
|
|
@@ -727,7 +727,7 @@ snapshots:
|
|
|
727
727
|
socks-proxy-agent@8.0.5:
|
|
728
728
|
dependencies:
|
|
729
729
|
agent-base: 7.1.4
|
|
730
|
-
debug: 4.4.
|
|
730
|
+
debug: 4.4.3
|
|
731
731
|
socks: 2.8.7
|
|
732
732
|
transitivePeerDependencies:
|
|
733
733
|
- supports-color
|
|
@@ -755,7 +755,7 @@ snapshots:
|
|
|
755
755
|
dependencies:
|
|
756
756
|
eastasianwidth: 0.2.0
|
|
757
757
|
emoji-regex: 9.2.2
|
|
758
|
-
strip-ansi: 7.1.
|
|
758
|
+
strip-ansi: 7.1.2
|
|
759
759
|
optional: true
|
|
760
760
|
|
|
761
761
|
strip-ansi@6.0.1:
|
|
@@ -763,9 +763,9 @@ snapshots:
|
|
|
763
763
|
ansi-regex: 5.0.1
|
|
764
764
|
optional: true
|
|
765
765
|
|
|
766
|
-
strip-ansi@7.1.
|
|
766
|
+
strip-ansi@7.1.2:
|
|
767
767
|
dependencies:
|
|
768
|
-
ansi-regex: 6.2.
|
|
768
|
+
ansi-regex: 6.2.2
|
|
769
769
|
optional: true
|
|
770
770
|
|
|
771
771
|
tar@7.4.3:
|
|
@@ -809,9 +809,9 @@ snapshots:
|
|
|
809
809
|
|
|
810
810
|
wrap-ansi@8.1.0:
|
|
811
811
|
dependencies:
|
|
812
|
-
ansi-styles: 6.2.
|
|
812
|
+
ansi-styles: 6.2.3
|
|
813
813
|
string-width: 5.1.2
|
|
814
|
-
strip-ansi: 7.1.
|
|
814
|
+
strip-ansi: 7.1.2
|
|
815
815
|
optional: true
|
|
816
816
|
|
|
817
817
|
yallist@4.0.0:
|
|
@@ -109,7 +109,7 @@ function assembleStyles() {
|
|
|
109
109
|
// From https://github.com/Qix-/color-convert/blob/3f0e0d4e92e235796ccb17f6e85c72094a651f49/conversions.js
|
|
110
110
|
Object.defineProperties(styles, {
|
|
111
111
|
rgbToAnsi256: {
|
|
112
|
-
value
|
|
112
|
+
value(red, green, blue) {
|
|
113
113
|
// We use the extended greyscale palette here, with the exception of
|
|
114
114
|
// black and white. normal palette only has 4 greyscale shades.
|
|
115
115
|
if (red === green && green === blue) {
|
|
@@ -132,7 +132,7 @@ function assembleStyles() {
|
|
|
132
132
|
enumerable: false,
|
|
133
133
|
},
|
|
134
134
|
hexToRgb: {
|
|
135
|
-
value
|
|
135
|
+
value(hex) {
|
|
136
136
|
const matches = /[a-f\d]{6}|[a-f\d]{3}/i.exec(hex.toString(16));
|
|
137
137
|
if (!matches) {
|
|
138
138
|
return [0, 0, 0];
|
|
@@ -161,7 +161,7 @@ function assembleStyles() {
|
|
|
161
161
|
enumerable: false,
|
|
162
162
|
},
|
|
163
163
|
ansi256ToAnsi: {
|
|
164
|
-
value
|
|
164
|
+
value(code) {
|
|
165
165
|
if (code < 8) {
|
|
166
166
|
return 30 + code;
|
|
167
167
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ansi-styles",
|
|
3
|
-
"version": "6.2.
|
|
3
|
+
"version": "6.2.3",
|
|
4
4
|
"description": "ANSI escape codes for styling strings in the terminal",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "chalk/ansi-styles",
|
|
@@ -46,9 +46,9 @@
|
|
|
46
46
|
"text"
|
|
47
47
|
],
|
|
48
48
|
"devDependencies": {
|
|
49
|
-
"ava": "^
|
|
49
|
+
"ava": "^6.1.3",
|
|
50
50
|
"svg-term-cli": "^2.1.1",
|
|
51
|
-
"tsd": "^0.
|
|
52
|
-
"xo": "^0.
|
|
51
|
+
"tsd": "^0.31.1",
|
|
52
|
+
"xo": "^0.58.0"
|
|
53
53
|
}
|
|
54
54
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "strip-ansi",
|
|
3
|
-
"version": "7.1.
|
|
3
|
+
"version": "7.1.2",
|
|
4
4
|
"description": "Strip ANSI escape codes from a string",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "chalk/strip-ansi",
|
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
},
|
|
13
13
|
"type": "module",
|
|
14
14
|
"exports": "./index.js",
|
|
15
|
+
"types": "./index.d.ts",
|
|
16
|
+
"sideEffects": false,
|
|
15
17
|
"engines": {
|
|
16
18
|
"node": ">=12"
|
|
17
19
|
},
|
package/dist/pnpm.cjs
CHANGED
|
@@ -5754,7 +5754,7 @@ var require_lib4 = __commonJS({
|
|
|
5754
5754
|
var load_json_file_1 = __importDefault2(require_load_json_file());
|
|
5755
5755
|
var defaultManifest = {
|
|
5756
5756
|
name: true ? "pnpm" : "pnpm",
|
|
5757
|
-
version: true ? "10.
|
|
5757
|
+
version: true ? "10.16.1" : "0.0.0"
|
|
5758
5758
|
};
|
|
5759
5759
|
var pkgJson;
|
|
5760
5760
|
if (require.main == null) {
|
|
@@ -6223,7 +6223,7 @@ var require_lib5 = __commonJS({
|
|
|
6223
6223
|
exports2.WORKSPACE_MANIFEST_FILENAME = "pnpm-workspace.yaml";
|
|
6224
6224
|
exports2.ABBREVIATED_META_DIR = "metadata-v1.3";
|
|
6225
6225
|
exports2.FULL_META_DIR = "metadata-full-v1.3";
|
|
6226
|
-
exports2.FULL_FILTERED_META_DIR = "metadata-v1.3";
|
|
6226
|
+
exports2.FULL_FILTERED_META_DIR = "metadata-ff-v1.3";
|
|
6227
6227
|
exports2.USEFUL_NON_ROOT_PNPM_FIELDS = ["executionEnv"];
|
|
6228
6228
|
function getNodeBinLocationForCurrentOS(platform = process.platform) {
|
|
6229
6229
|
return platform === "win32" ? "node.exe" : "bin/node";
|
|
@@ -17517,6 +17517,8 @@ var require_types2 = __commonJS({
|
|
|
17517
17517
|
maxsockets: Number,
|
|
17518
17518
|
"modules-cache-max-age": Number,
|
|
17519
17519
|
"dlx-cache-max-age": Number,
|
|
17520
|
+
"minimum-release-age": Number,
|
|
17521
|
+
"minimum-release-age-exclude": [String, Array],
|
|
17520
17522
|
"modules-dir": String,
|
|
17521
17523
|
"network-concurrency": Number,
|
|
17522
17524
|
"node-linker": ["pnp", "isolated", "hoisted"],
|
|
@@ -43440,12 +43442,15 @@ var require_lru_cache = __commonJS({
|
|
|
43440
43442
|
}
|
|
43441
43443
|
});
|
|
43442
43444
|
|
|
43443
|
-
// ../node_modules/.pnpm/@pnpm+constants@1001.
|
|
43445
|
+
// ../node_modules/.pnpm/@pnpm+constants@1001.3.0/node_modules/@pnpm/constants/lib/index.js
|
|
43444
43446
|
var require_lib25 = __commonJS({
|
|
43445
|
-
"../node_modules/.pnpm/@pnpm+constants@1001.
|
|
43447
|
+
"../node_modules/.pnpm/@pnpm+constants@1001.3.0/node_modules/@pnpm/constants/lib/index.js"(exports2) {
|
|
43446
43448
|
"use strict";
|
|
43447
43449
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
43448
43450
|
exports2.USEFUL_NON_ROOT_PNPM_FIELDS = exports2.FULL_FILTERED_META_DIR = exports2.FULL_META_DIR = exports2.ABBREVIATED_META_DIR = exports2.WORKSPACE_MANIFEST_FILENAME = exports2.STORE_VERSION = exports2.LAYOUT_VERSION = exports2.ENGINE_NAME = exports2.MANIFEST_BASE_NAMES = exports2.LOCKFILE_VERSION = exports2.LOCKFILE_MAJOR_VERSION = exports2.WANTED_LOCKFILE = void 0;
|
|
43451
|
+
exports2.getNodeBinLocationForCurrentOS = getNodeBinLocationForCurrentOS;
|
|
43452
|
+
exports2.getDenoBinLocationForCurrentOS = getDenoBinLocationForCurrentOS;
|
|
43453
|
+
exports2.getBunBinLocationForCurrentOS = getBunBinLocationForCurrentOS;
|
|
43449
43454
|
exports2.WANTED_LOCKFILE = "pnpm-lock.yaml";
|
|
43450
43455
|
exports2.LOCKFILE_MAJOR_VERSION = "9";
|
|
43451
43456
|
exports2.LOCKFILE_VERSION = `${exports2.LOCKFILE_MAJOR_VERSION}.0`;
|
|
@@ -43458,17 +43463,31 @@ var require_lib25 = __commonJS({
|
|
|
43458
43463
|
exports2.FULL_META_DIR = "metadata-full-v1.3";
|
|
43459
43464
|
exports2.FULL_FILTERED_META_DIR = "metadata-v1.3";
|
|
43460
43465
|
exports2.USEFUL_NON_ROOT_PNPM_FIELDS = ["executionEnv"];
|
|
43466
|
+
function getNodeBinLocationForCurrentOS(platform = process.platform) {
|
|
43467
|
+
return platform === "win32" ? "node.exe" : "bin/node";
|
|
43468
|
+
}
|
|
43469
|
+
function getDenoBinLocationForCurrentOS(platform = process.platform) {
|
|
43470
|
+
return platform === "win32" ? "deno.exe" : "deno";
|
|
43471
|
+
}
|
|
43472
|
+
function getBunBinLocationForCurrentOS(platform = process.platform) {
|
|
43473
|
+
return platform === "win32" ? "bun.exe" : "bun";
|
|
43474
|
+
}
|
|
43461
43475
|
}
|
|
43462
43476
|
});
|
|
43463
43477
|
|
|
43464
|
-
// ../node_modules/.pnpm/@pnpm+error@1000.0.
|
|
43478
|
+
// ../node_modules/.pnpm/@pnpm+error@1000.0.4/node_modules/@pnpm/error/lib/index.js
|
|
43465
43479
|
var require_lib26 = __commonJS({
|
|
43466
|
-
"../node_modules/.pnpm/@pnpm+error@1000.0.
|
|
43480
|
+
"../node_modules/.pnpm/@pnpm+error@1000.0.4/node_modules/@pnpm/error/lib/index.js"(exports2) {
|
|
43467
43481
|
"use strict";
|
|
43468
43482
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
43469
43483
|
exports2.LockfileMissingDependencyError = exports2.FetchError = exports2.PnpmError = void 0;
|
|
43470
43484
|
var constants_1 = require_lib25();
|
|
43471
43485
|
var PnpmError = class extends Error {
|
|
43486
|
+
code;
|
|
43487
|
+
hint;
|
|
43488
|
+
attempts;
|
|
43489
|
+
prefix;
|
|
43490
|
+
pkgsStack;
|
|
43472
43491
|
constructor(code, message, opts) {
|
|
43473
43492
|
super(message);
|
|
43474
43493
|
this.code = code.startsWith("ERR_PNPM_") ? code : `ERR_PNPM_${code}`;
|
|
@@ -43478,6 +43497,8 @@ var require_lib26 = __commonJS({
|
|
|
43478
43497
|
};
|
|
43479
43498
|
exports2.PnpmError = PnpmError;
|
|
43480
43499
|
var FetchError = class extends PnpmError {
|
|
43500
|
+
response;
|
|
43501
|
+
request;
|
|
43481
43502
|
constructor(request, response, hint) {
|
|
43482
43503
|
const _request = {
|
|
43483
43504
|
url: request.url
|
|
@@ -60879,9 +60900,14 @@ var require_pickPackageFromMeta = __commonJS({
|
|
|
60879
60900
|
exports2.pickLowestVersionByVersionRange = pickLowestVersionByVersionRange;
|
|
60880
60901
|
exports2.pickVersionByVersionRange = pickVersionByVersionRange;
|
|
60881
60902
|
var error_1 = require_lib6();
|
|
60903
|
+
var logger_1 = require_lib();
|
|
60882
60904
|
var semver_12 = __importDefault2(require_semver2());
|
|
60883
60905
|
var util_1 = __importDefault2(require("util"));
|
|
60884
60906
|
function pickPackageFromMeta(pickVersionByVersionRangeFn, spec, preferredVersionSelectors, meta, publishedBy) {
|
|
60907
|
+
if (publishedBy) {
|
|
60908
|
+
assertMetaHasTime(meta);
|
|
60909
|
+
meta = filterMetaByPublishedDate(meta, publishedBy);
|
|
60910
|
+
}
|
|
60885
60911
|
if ((!meta.versions || Object.keys(meta.versions).length === 0) && !publishedBy) {
|
|
60886
60912
|
if (meta.time?.unpublished?.versions?.length) {
|
|
60887
60913
|
throw new error_1.PnpmError("UNPUBLISHED_PKG", `No versions available for ${spec.name} because it was unpublished`);
|
|
@@ -60898,7 +60924,12 @@ var require_pickPackageFromMeta = __commonJS({
|
|
|
60898
60924
|
version2 = meta["dist-tags"][spec.fetchSpec];
|
|
60899
60925
|
break;
|
|
60900
60926
|
case "range":
|
|
60901
|
-
version2 = pickVersionByVersionRangeFn(
|
|
60927
|
+
version2 = pickVersionByVersionRangeFn({
|
|
60928
|
+
meta,
|
|
60929
|
+
versionRange: spec.fetchSpec,
|
|
60930
|
+
preferredVersionSelectors,
|
|
60931
|
+
publishedBy
|
|
60932
|
+
});
|
|
60902
60933
|
break;
|
|
60903
60934
|
}
|
|
60904
60935
|
if (!version2)
|
|
@@ -60915,6 +60946,11 @@ var require_pickPackageFromMeta = __commonJS({
|
|
|
60915
60946
|
throw new error_1.PnpmError("MALFORMED_METADATA", `Received malformed metadata for "${spec.name}"`, { hint: "This might mean that the package was unpublished from the registry" });
|
|
60916
60947
|
}
|
|
60917
60948
|
}
|
|
60949
|
+
function assertMetaHasTime(meta) {
|
|
60950
|
+
if (meta.time == null) {
|
|
60951
|
+
throw new error_1.PnpmError("MISSING_TIME", `The metadata of ${meta.name} is missing the "time" field`);
|
|
60952
|
+
}
|
|
60953
|
+
}
|
|
60918
60954
|
var semverRangeCache = /* @__PURE__ */ new Map();
|
|
60919
60955
|
function semverSatisfiesLoose(version2, range) {
|
|
60920
60956
|
let semverRange = semverRangeCache.get(range);
|
|
@@ -60935,9 +60971,9 @@ var require_pickPackageFromMeta = __commonJS({
|
|
|
60935
60971
|
}
|
|
60936
60972
|
return false;
|
|
60937
60973
|
}
|
|
60938
|
-
function pickLowestVersionByVersionRange(meta, versionRange,
|
|
60939
|
-
if (
|
|
60940
|
-
const prioritizedPreferredVersions = prioritizePreferredVersions(meta, versionRange,
|
|
60974
|
+
function pickLowestVersionByVersionRange({ meta, versionRange, preferredVersionSelectors }) {
|
|
60975
|
+
if (preferredVersionSelectors != null && Object.keys(preferredVersionSelectors).length > 0) {
|
|
60976
|
+
const prioritizedPreferredVersions = prioritizePreferredVersions(meta, versionRange, preferredVersionSelectors);
|
|
60941
60977
|
for (const preferredVersions of prioritizedPreferredVersions) {
|
|
60942
60978
|
const preferredVersion = semver_12.default.minSatisfying(preferredVersions, versionRange, true);
|
|
60943
60979
|
if (preferredVersion) {
|
|
@@ -60950,10 +60986,10 @@ var require_pickPackageFromMeta = __commonJS({
|
|
|
60950
60986
|
}
|
|
60951
60987
|
return semver_12.default.minSatisfying(Object.keys(meta.versions), versionRange, true);
|
|
60952
60988
|
}
|
|
60953
|
-
function pickVersionByVersionRange(meta, versionRange,
|
|
60954
|
-
|
|
60955
|
-
if (
|
|
60956
|
-
const prioritizedPreferredVersions = prioritizePreferredVersions(meta, versionRange,
|
|
60989
|
+
function pickVersionByVersionRange({ meta, versionRange, preferredVersionSelectors }) {
|
|
60990
|
+
const latest = meta["dist-tags"].latest;
|
|
60991
|
+
if (preferredVersionSelectors != null && Object.keys(preferredVersionSelectors).length > 0) {
|
|
60992
|
+
const prioritizedPreferredVersions = prioritizePreferredVersions(meta, versionRange, preferredVersionSelectors);
|
|
60957
60993
|
for (const preferredVersions of prioritizedPreferredVersions) {
|
|
60958
60994
|
if (preferredVersions.includes(latest) && semverSatisfiesLoose(latest, versionRange)) {
|
|
60959
60995
|
return latest;
|
|
@@ -60964,16 +61000,7 @@ var require_pickPackageFromMeta = __commonJS({
|
|
|
60964
61000
|
}
|
|
60965
61001
|
}
|
|
60966
61002
|
}
|
|
60967
|
-
|
|
60968
|
-
if (publishedBy) {
|
|
60969
|
-
if (meta.time == null) {
|
|
60970
|
-
throw new error_1.PnpmError("MISSING_TIME", `The metadata of ${meta.name} is missing the "time" field`);
|
|
60971
|
-
}
|
|
60972
|
-
versions = versions.filter((version2) => new Date(meta.time[version2]) <= publishedBy);
|
|
60973
|
-
if (!versions.includes(latest)) {
|
|
60974
|
-
latest = void 0;
|
|
60975
|
-
}
|
|
60976
|
-
}
|
|
61003
|
+
const versions = Object.keys(meta.versions);
|
|
60977
61004
|
if (latest && (versionRange === "*" || semverSatisfiesLoose(latest, versionRange))) {
|
|
60978
61005
|
return latest;
|
|
60979
61006
|
}
|
|
@@ -61035,6 +61062,60 @@ var require_pickPackageFromMeta = __commonJS({
|
|
|
61035
61062
|
return Object.keys(versionsByWeight).sort((a, b) => parseInt(b, 10) - parseInt(a, 10)).map((weight) => versionsByWeight[parseInt(weight, 10)]);
|
|
61036
61063
|
}
|
|
61037
61064
|
};
|
|
61065
|
+
function filterMetaByPublishedDate(meta, publishedBy) {
|
|
61066
|
+
const versionsWithinDate = {};
|
|
61067
|
+
for (const version2 in meta.versions) {
|
|
61068
|
+
if (!Object.hasOwn(meta.versions, version2))
|
|
61069
|
+
continue;
|
|
61070
|
+
const timeStr = meta.time[version2];
|
|
61071
|
+
if (timeStr && new Date(timeStr) <= publishedBy) {
|
|
61072
|
+
versionsWithinDate[version2] = meta.versions[version2];
|
|
61073
|
+
}
|
|
61074
|
+
}
|
|
61075
|
+
const distTagsWithinDate = {};
|
|
61076
|
+
const allDistTags = meta["dist-tags"] ?? {};
|
|
61077
|
+
for (const tag in allDistTags) {
|
|
61078
|
+
if (!Object.hasOwn(allDistTags, tag))
|
|
61079
|
+
continue;
|
|
61080
|
+
const distTagVersion = allDistTags[tag];
|
|
61081
|
+
if (versionsWithinDate[distTagVersion]) {
|
|
61082
|
+
distTagsWithinDate[tag] = distTagVersion;
|
|
61083
|
+
continue;
|
|
61084
|
+
}
|
|
61085
|
+
let originalSemVer = null;
|
|
61086
|
+
try {
|
|
61087
|
+
originalSemVer = new semver_12.default.SemVer(distTagVersion, true);
|
|
61088
|
+
} catch {
|
|
61089
|
+
continue;
|
|
61090
|
+
}
|
|
61091
|
+
const originalMajor = originalSemVer.major;
|
|
61092
|
+
let bestVersion;
|
|
61093
|
+
const originalMajorPrefix = `${originalMajor}.`;
|
|
61094
|
+
for (const candidate in versionsWithinDate) {
|
|
61095
|
+
if (!Object.hasOwn(versionsWithinDate, candidate) || !candidate.startsWith(originalMajorPrefix))
|
|
61096
|
+
continue;
|
|
61097
|
+
if (!bestVersion) {
|
|
61098
|
+
bestVersion = candidate;
|
|
61099
|
+
} else {
|
|
61100
|
+
try {
|
|
61101
|
+
if (semver_12.default.gt(candidate, bestVersion, true)) {
|
|
61102
|
+
bestVersion = candidate;
|
|
61103
|
+
}
|
|
61104
|
+
} catch (err) {
|
|
61105
|
+
(0, logger_1.globalWarn)(`Failed to compare semver versions ${candidate} and ${bestVersion} from packument of ${meta.name}, skipping candidate version.`);
|
|
61106
|
+
}
|
|
61107
|
+
}
|
|
61108
|
+
}
|
|
61109
|
+
if (bestVersion) {
|
|
61110
|
+
distTagsWithinDate[tag] = bestVersion;
|
|
61111
|
+
}
|
|
61112
|
+
}
|
|
61113
|
+
return {
|
|
61114
|
+
...meta,
|
|
61115
|
+
versions: versionsWithinDate,
|
|
61116
|
+
"dist-tags": distTagsWithinDate
|
|
61117
|
+
};
|
|
61118
|
+
}
|
|
61038
61119
|
}
|
|
61039
61120
|
});
|
|
61040
61121
|
|
|
@@ -61076,15 +61157,18 @@ var require_pickPackage = __commonJS({
|
|
|
61076
61157
|
}
|
|
61077
61158
|
}
|
|
61078
61159
|
}
|
|
61160
|
+
function pickPackageFromMetaUsingTimeStrict(spec, preferredVersionSelectors, meta, publishedBy) {
|
|
61161
|
+
return (0, pickPackageFromMeta_js_1.pickPackageFromMeta)(pickPackageFromMeta_js_1.pickVersionByVersionRange, spec, preferredVersionSelectors, meta, publishedBy);
|
|
61162
|
+
}
|
|
61079
61163
|
function pickPackageFromMetaUsingTime(spec, preferredVersionSelectors, meta, publishedBy) {
|
|
61080
61164
|
const pickedPackage = (0, pickPackageFromMeta_js_1.pickPackageFromMeta)(pickPackageFromMeta_js_1.pickVersionByVersionRange, spec, preferredVersionSelectors, meta, publishedBy);
|
|
61081
61165
|
if (pickedPackage)
|
|
61082
61166
|
return pickedPackage;
|
|
61083
|
-
return (0, pickPackageFromMeta_js_1.pickPackageFromMeta)(pickPackageFromMeta_js_1.pickLowestVersionByVersionRange, spec, preferredVersionSelectors, meta
|
|
61167
|
+
return (0, pickPackageFromMeta_js_1.pickPackageFromMeta)(pickPackageFromMeta_js_1.pickLowestVersionByVersionRange, spec, preferredVersionSelectors, meta);
|
|
61084
61168
|
}
|
|
61085
61169
|
async function pickPackage(ctx, spec, opts) {
|
|
61086
61170
|
opts = opts || {};
|
|
61087
|
-
let _pickPackageFromMeta = opts.publishedBy ? pickPackageFromMetaUsingTime : pickPackageFromMeta_js_1.pickPackageFromMeta.bind(null, opts.pickLowestVersion ? pickPackageFromMeta_js_1.pickLowestVersionByVersionRange : pickPackageFromMeta_js_1.pickVersionByVersionRange);
|
|
61171
|
+
let _pickPackageFromMeta = opts.publishedBy ? ctx.strictPublishedByCheck ? pickPackageFromMetaUsingTimeStrict : pickPackageFromMetaUsingTime : pickPackageFromMeta_js_1.pickPackageFromMeta.bind(null, opts.pickLowestVersion ? pickPackageFromMeta_js_1.pickLowestVersionByVersionRange : pickPackageFromMeta_js_1.pickVersionByVersionRange);
|
|
61088
61172
|
if (opts.updateToLatest) {
|
|
61089
61173
|
const _pickPackageBase = _pickPackageFromMeta;
|
|
61090
61174
|
_pickPackageFromMeta = (spec2, ...rest) => {
|
|
@@ -61144,12 +61228,18 @@ var require_pickPackage = __commonJS({
|
|
|
61144
61228
|
if (opts.publishedBy) {
|
|
61145
61229
|
metaCachedInStore = metaCachedInStore ?? await limit(async () => loadMeta(pkgMirror));
|
|
61146
61230
|
if (metaCachedInStore?.cachedAt && new Date(metaCachedInStore.cachedAt) >= opts.publishedBy) {
|
|
61147
|
-
|
|
61148
|
-
|
|
61149
|
-
|
|
61150
|
-
|
|
61151
|
-
|
|
61152
|
-
|
|
61231
|
+
try {
|
|
61232
|
+
const pickedPackage = _pickPackageFromMeta(spec, opts.preferredVersionSelectors, metaCachedInStore, opts.publishedBy);
|
|
61233
|
+
if (pickedPackage) {
|
|
61234
|
+
return {
|
|
61235
|
+
meta: metaCachedInStore,
|
|
61236
|
+
pickedPackage
|
|
61237
|
+
};
|
|
61238
|
+
}
|
|
61239
|
+
} catch (err) {
|
|
61240
|
+
if (ctx.strictPublishedByCheck) {
|
|
61241
|
+
throw err;
|
|
61242
|
+
}
|
|
61153
61243
|
}
|
|
61154
61244
|
}
|
|
61155
61245
|
}
|
|
@@ -61784,7 +61874,8 @@ var require_lib46 = __commonJS({
|
|
|
61784
61874
|
metaDir: opts.fullMetadata ? opts.filterMetadata ? constants_1.FULL_FILTERED_META_DIR : constants_1.FULL_META_DIR : constants_1.ABBREVIATED_META_DIR,
|
|
61785
61875
|
offline: opts.offline,
|
|
61786
61876
|
preferOffline: opts.preferOffline,
|
|
61787
|
-
cacheDir: opts.cacheDir
|
|
61877
|
+
cacheDir: opts.cacheDir,
|
|
61878
|
+
strictPublishedByCheck: opts.strictPublishedByCheck
|
|
61788
61879
|
}),
|
|
61789
61880
|
registries: opts.registries,
|
|
61790
61881
|
saveWorkspaceProtocol: opts.saveWorkspaceProtocol
|
|
@@ -68003,7 +68094,9 @@ var require_lib58 = __commonJS({
|
|
|
68003
68094
|
return mod && mod.__esModule ? mod : { "default": mod };
|
|
68004
68095
|
};
|
|
68005
68096
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
68097
|
+
exports2.readPackageJsonSync = readPackageJsonSync;
|
|
68006
68098
|
exports2.readPackageJson = readPackageJson;
|
|
68099
|
+
exports2.readPackageJsonFromDirSync = readPackageJsonFromDirSync;
|
|
68007
68100
|
exports2.readPackageJsonFromDir = readPackageJsonFromDir;
|
|
68008
68101
|
exports2.safeReadPackageJson = safeReadPackageJson;
|
|
68009
68102
|
exports2.safeReadPackageJsonFromDir = safeReadPackageJsonFromDir;
|
|
@@ -68011,6 +68104,17 @@ var require_lib58 = __commonJS({
|
|
|
68011
68104
|
var error_1 = require_lib6();
|
|
68012
68105
|
var load_json_file_1 = __importDefault2(require_load_json_file());
|
|
68013
68106
|
var normalize_package_data_1 = __importDefault2(require_normalize());
|
|
68107
|
+
function readPackageJsonSync(pkgPath) {
|
|
68108
|
+
try {
|
|
68109
|
+
const manifest = load_json_file_1.default.sync(pkgPath);
|
|
68110
|
+
(0, normalize_package_data_1.default)(manifest);
|
|
68111
|
+
return manifest;
|
|
68112
|
+
} catch (err) {
|
|
68113
|
+
if (err.code)
|
|
68114
|
+
throw err;
|
|
68115
|
+
throw new error_1.PnpmError("BAD_PACKAGE_JSON", `${pkgPath}: ${err.message}`);
|
|
68116
|
+
}
|
|
68117
|
+
}
|
|
68014
68118
|
async function readPackageJson(pkgPath) {
|
|
68015
68119
|
try {
|
|
68016
68120
|
const manifest = await (0, load_json_file_1.default)(pkgPath);
|
|
@@ -68022,6 +68126,9 @@ var require_lib58 = __commonJS({
|
|
|
68022
68126
|
throw new error_1.PnpmError("BAD_PACKAGE_JSON", `${pkgPath}: ${err.message}`);
|
|
68023
68127
|
}
|
|
68024
68128
|
}
|
|
68129
|
+
function readPackageJsonFromDirSync(pkgPath) {
|
|
68130
|
+
return readPackageJsonSync(path_1.default.join(pkgPath, "package.json"));
|
|
68131
|
+
}
|
|
68025
68132
|
async function readPackageJsonFromDir(pkgPath) {
|
|
68026
68133
|
return readPackageJson(path_1.default.join(pkgPath, "package.json"));
|
|
68027
68134
|
}
|
|
@@ -68040,9 +68147,9 @@ var require_lib58 = __commonJS({
|
|
|
68040
68147
|
}
|
|
68041
68148
|
});
|
|
68042
68149
|
|
|
68043
|
-
// ../node_modules/.pnpm/@pnpm+npm-lifecycle@
|
|
68150
|
+
// ../node_modules/.pnpm/@pnpm+npm-lifecycle@1001.0.0_typanion@3.14.0/node_modules/@pnpm/npm-lifecycle/lib/spawn.js
|
|
68044
68151
|
var require_spawn = __commonJS({
|
|
68045
|
-
"../node_modules/.pnpm/@pnpm+npm-lifecycle@
|
|
68152
|
+
"../node_modules/.pnpm/@pnpm+npm-lifecycle@1001.0.0_typanion@3.14.0/node_modules/@pnpm/npm-lifecycle/lib/spawn.js"(exports2, module2) {
|
|
68046
68153
|
"use strict";
|
|
68047
68154
|
module2.exports = spawn;
|
|
68048
68155
|
var _spawn = require("child_process").spawn;
|
|
@@ -92396,9 +92503,9 @@ var require_lib63 = __commonJS({
|
|
|
92396
92503
|
}
|
|
92397
92504
|
});
|
|
92398
92505
|
|
|
92399
|
-
// ../node_modules/.pnpm/@pnpm+npm-lifecycle@
|
|
92506
|
+
// ../node_modules/.pnpm/@pnpm+npm-lifecycle@1001.0.0_typanion@3.14.0/node_modules/@pnpm/npm-lifecycle/lib/extendPath.js
|
|
92400
92507
|
var require_extendPath = __commonJS({
|
|
92401
|
-
"../node_modules/.pnpm/@pnpm+npm-lifecycle@
|
|
92508
|
+
"../node_modules/.pnpm/@pnpm+npm-lifecycle@1001.0.0_typanion@3.14.0/node_modules/@pnpm/npm-lifecycle/lib/extendPath.js"(exports2, module2) {
|
|
92402
92509
|
var fs = require("fs");
|
|
92403
92510
|
var path2 = require("path");
|
|
92404
92511
|
var which = require_lib63();
|
|
@@ -92447,9 +92554,9 @@ var require_extendPath = __commonJS({
|
|
|
92447
92554
|
}
|
|
92448
92555
|
});
|
|
92449
92556
|
|
|
92450
|
-
// ../node_modules/.pnpm/@pnpm+npm-lifecycle@
|
|
92557
|
+
// ../node_modules/.pnpm/@pnpm+npm-lifecycle@1001.0.0_typanion@3.14.0/node_modules/@pnpm/npm-lifecycle/index.js
|
|
92451
92558
|
var require_npm_lifecycle = __commonJS({
|
|
92452
|
-
"../node_modules/.pnpm/@pnpm+npm-lifecycle@
|
|
92559
|
+
"../node_modules/.pnpm/@pnpm+npm-lifecycle@1001.0.0_typanion@3.14.0/node_modules/@pnpm/npm-lifecycle/index.js"(exports2, module2) {
|
|
92453
92560
|
"use strict";
|
|
92454
92561
|
exports2 = module2.exports = lifecycle;
|
|
92455
92562
|
exports2.makeEnv = makeEnv;
|
|
@@ -92526,7 +92633,15 @@ var require_npm_lifecycle = __commonJS({
|
|
|
92526
92633
|
env[key] = value;
|
|
92527
92634
|
}
|
|
92528
92635
|
}
|
|
92529
|
-
if (!opts.unsafePerm)
|
|
92636
|
+
if (!opts.unsafePerm) {
|
|
92637
|
+
const tmpdir = path2.join(wd2, "node_modules", ".tmp");
|
|
92638
|
+
try {
|
|
92639
|
+
fs.mkdirSync(tmpdir, { recursive: true });
|
|
92640
|
+
} catch (err) {
|
|
92641
|
+
if (err.code !== "EEXIST") throw err;
|
|
92642
|
+
}
|
|
92643
|
+
env.TMPDIR = tmpdir;
|
|
92644
|
+
}
|
|
92530
92645
|
lifecycle_(pkg, stage, wd2, opts, env, (er2) => {
|
|
92531
92646
|
if (er2) return reject(er2);
|
|
92532
92647
|
return resolve();
|
|
@@ -92682,7 +92797,7 @@ var require_npm_lifecycle = __commonJS({
|
|
|
92682
92797
|
proc.on("close", (code, signal) => {
|
|
92683
92798
|
opts.log.silly("lifecycle", logid(pkg, stage), "Returned: code:", code, " signal:", signal);
|
|
92684
92799
|
let err;
|
|
92685
|
-
if (signal
|
|
92800
|
+
if (signal) {
|
|
92686
92801
|
err = new PnpmError("CHILD_PROCESS_FAILED", `Command failed with signal "${signal}"`);
|
|
92687
92802
|
process.kill(process.pid, signal);
|
|
92688
92803
|
} else if (code) {
|
|
@@ -92719,8 +92834,9 @@ ${er.message}`;
|
|
|
92719
92834
|
er.pkgname = pkg.name;
|
|
92720
92835
|
}
|
|
92721
92836
|
process.removeListener("SIGTERM", procKill);
|
|
92722
|
-
process.removeListener("SIGTERM", procInterrupt);
|
|
92723
92837
|
process.removeListener("SIGINT", procKill);
|
|
92838
|
+
process.removeListener("SIGINT", procInterrupt);
|
|
92839
|
+
process.removeListener("exit", procKill);
|
|
92724
92840
|
return cb(er);
|
|
92725
92841
|
}
|
|
92726
92842
|
let called = false;
|
|
@@ -92731,9 +92847,6 @@ ${er.message}`;
|
|
|
92731
92847
|
}
|
|
92732
92848
|
function procInterrupt() {
|
|
92733
92849
|
proc.kill("SIGINT");
|
|
92734
|
-
proc.on("exit", () => {
|
|
92735
|
-
process.exit();
|
|
92736
|
-
});
|
|
92737
92850
|
process.once("SIGINT", procKill);
|
|
92738
92851
|
}
|
|
92739
92852
|
}
|
|
@@ -107693,6 +107806,9 @@ var require_checkEngine = __commonJS({
|
|
|
107693
107806
|
return null;
|
|
107694
107807
|
const unsatisfiedWanted = {};
|
|
107695
107808
|
if (wantedEngine.node && !semver_12.default.satisfies(currentEngine.node, wantedEngine.node, { includePrerelease: true })) {
|
|
107809
|
+
if (!semver_12.default.valid(currentEngine.node)) {
|
|
107810
|
+
throw new error_1.PnpmError("INVALID_NODE_VERSION", `The nodeVersion setting is "${currentEngine.node}", which is not exact semver version`);
|
|
107811
|
+
}
|
|
107696
107812
|
unsatisfiedWanted.node = wantedEngine.node;
|
|
107697
107813
|
}
|
|
107698
107814
|
if (currentEngine.pnpm && wantedEngine.pnpm && !semver_12.default.satisfies(currentEngine.pnpm, wantedEngine.pnpm, { includePrerelease: true })) {
|
|
@@ -109625,7 +109741,7 @@ var require_createNewStoreController = __commonJS({
|
|
|
109625
109741
|
var package_store_1 = require_lib88();
|
|
109626
109742
|
var cli_meta_1 = require_lib4();
|
|
109627
109743
|
async function createNewStoreController(opts) {
|
|
109628
|
-
const fullMetadata = opts.fetchFullMetadata ?? (opts.resolutionMode === "time-based" && !opts.registrySupportsTimeField);
|
|
109744
|
+
const fullMetadata = opts.fetchFullMetadata ?? ((opts.resolutionMode === "time-based" || Boolean(opts.minimumReleaseAge)) && !opts.registrySupportsTimeField);
|
|
109629
109745
|
const { resolve, fetchers, clearResolutionCache } = (0, client_1.createClient)({
|
|
109630
109746
|
customFetchers: opts.hooks?.fetchers,
|
|
109631
109747
|
userConfig: opts.userConfig,
|
|
@@ -109661,7 +109777,8 @@ var require_createNewStoreController = __commonJS({
|
|
|
109661
109777
|
resolveSymlinksInInjectedDirs: opts.resolveSymlinksInInjectedDirs,
|
|
109662
109778
|
includeOnlyPackageFiles: !opts.deployAllFiles,
|
|
109663
109779
|
saveWorkspaceProtocol: opts.saveWorkspaceProtocol,
|
|
109664
|
-
preserveAbsolutePaths: opts.preserveAbsolutePaths
|
|
109780
|
+
preserveAbsolutePaths: opts.preserveAbsolutePaths,
|
|
109781
|
+
strictPublishedByCheck: Boolean(opts.minimumReleaseAge)
|
|
109665
109782
|
});
|
|
109666
109783
|
await fs_1.promises.mkdir(opts.storeDir, { recursive: true });
|
|
109667
109784
|
return {
|
|
@@ -110818,13 +110935,15 @@ var require_requireHooks = __commonJS({
|
|
|
110818
110935
|
entries.push({
|
|
110819
110936
|
file,
|
|
110820
110937
|
includeInChecksum,
|
|
110821
|
-
hooks: requirePnpmfileResult.pnpmfileModule?.hooks
|
|
110938
|
+
hooks: requirePnpmfileResult.pnpmfileModule?.hooks,
|
|
110939
|
+
finders: requirePnpmfileResult.pnpmfileModule?.finders
|
|
110822
110940
|
});
|
|
110823
110941
|
} else if (!optional) {
|
|
110824
110942
|
throw new error_1.PnpmError("PNPMFILE_NOT_FOUND", `pnpmfile at "${file}" is not found`);
|
|
110825
110943
|
}
|
|
110826
110944
|
}
|
|
110827
110945
|
}
|
|
110946
|
+
const mergedFinders = {};
|
|
110828
110947
|
const cookedHooks = {
|
|
110829
110948
|
readPackage: [],
|
|
110830
110949
|
preResolution: [],
|
|
@@ -110846,7 +110965,18 @@ var require_requireHooks = __commonJS({
|
|
|
110846
110965
|
}
|
|
110847
110966
|
let importProvider;
|
|
110848
110967
|
let fetchersProvider;
|
|
110849
|
-
|
|
110968
|
+
const finderProviders = {};
|
|
110969
|
+
for (const { hooks, file, finders } of entries) {
|
|
110970
|
+
if (finders != null) {
|
|
110971
|
+
for (const [finderName, finder] of Object.entries(finders)) {
|
|
110972
|
+
if (mergedFinders[finderName] != null) {
|
|
110973
|
+
const firstDefinedIn = finderProviders[finderName];
|
|
110974
|
+
throw new error_1.PnpmError("DUPLICATE_FINDER", `Finder "${finderName}" defined in both ${firstDefinedIn} and ${file}`);
|
|
110975
|
+
}
|
|
110976
|
+
mergedFinders[finderName] = finder;
|
|
110977
|
+
finderProviders[finderName] = file;
|
|
110978
|
+
}
|
|
110979
|
+
}
|
|
110850
110980
|
const fileHooks = hooks ?? {};
|
|
110851
110981
|
for (const hookName of ["readPackage", "afterAllResolved"]) {
|
|
110852
110982
|
const fn = fileHooks[hookName];
|
|
@@ -110889,6 +111019,7 @@ var require_requireHooks = __commonJS({
|
|
|
110889
111019
|
}
|
|
110890
111020
|
return {
|
|
110891
111021
|
hooks: cookedHooks,
|
|
111022
|
+
finders: mergedFinders,
|
|
110892
111023
|
resolvedPnpmfilePaths: entries.map(({ file }) => file)
|
|
110893
111024
|
};
|
|
110894
111025
|
}
|
|
@@ -110973,12 +111104,13 @@ var require_getConfig = __commonJS({
|
|
|
110973
111104
|
const configModulesDir = path_1.default.join(config.lockfileDir ?? config.rootProjectManifestDir, "node_modules/.pnpm-config");
|
|
110974
111105
|
pnpmfiles.unshift(...calcPnpmfilePathsOfPluginDeps(configModulesDir, config.configDependencies));
|
|
110975
111106
|
}
|
|
110976
|
-
const { hooks, resolvedPnpmfilePaths } = (0, pnpmfile_1.requireHooks)(config.lockfileDir ?? config.dir, {
|
|
111107
|
+
const { hooks, finders, resolvedPnpmfilePaths } = (0, pnpmfile_1.requireHooks)(config.lockfileDir ?? config.dir, {
|
|
110977
111108
|
globalPnpmfile: config.globalPnpmfile,
|
|
110978
111109
|
pnpmfiles,
|
|
110979
111110
|
tryLoadDefaultPnpmfile: config.tryLoadDefaultPnpmfile
|
|
110980
111111
|
});
|
|
110981
111112
|
config.hooks = hooks;
|
|
111113
|
+
config.finders = finders;
|
|
110982
111114
|
config.pnpmfile = resolvedPnpmfilePaths;
|
|
110983
111115
|
if (config.hooks?.updateConfig) {
|
|
110984
111116
|
for (const updateConfig of config.hooks.updateConfig) {
|
|
@@ -134303,9 +134435,9 @@ var require_abbrev = __commonJS({
|
|
|
134303
134435
|
}
|
|
134304
134436
|
});
|
|
134305
134437
|
|
|
134306
|
-
// ../node_modules/.pnpm/@pnpm+nopt@0.
|
|
134438
|
+
// ../node_modules/.pnpm/@pnpm+nopt@0.3.1/node_modules/@pnpm/nopt/lib/nopt.js
|
|
134307
134439
|
var require_nopt = __commonJS({
|
|
134308
|
-
"../node_modules/.pnpm/@pnpm+nopt@0.
|
|
134440
|
+
"../node_modules/.pnpm/@pnpm+nopt@0.3.1/node_modules/@pnpm/nopt/lib/nopt.js"(exports2, module2) {
|
|
134309
134441
|
var debug = process.env.DEBUG_NOPT || process.env.NOPT_DEBUG ? function() {
|
|
134310
134442
|
console.error.apply(console, arguments);
|
|
134311
134443
|
} : function() {
|
|
@@ -134315,6 +134447,14 @@ var require_nopt = __commonJS({
|
|
|
134315
134447
|
var Stream = require("stream").Stream;
|
|
134316
134448
|
var abbrev = require_abbrev();
|
|
134317
134449
|
var os = require("os");
|
|
134450
|
+
URL.parse ??= (input, base) => {
|
|
134451
|
+
try {
|
|
134452
|
+
const url2 = new URL(input, base);
|
|
134453
|
+
return url2;
|
|
134454
|
+
} catch {
|
|
134455
|
+
return null;
|
|
134456
|
+
}
|
|
134457
|
+
};
|
|
134318
134458
|
module2.exports = exports2 = nopt;
|
|
134319
134459
|
exports2.clean = clean;
|
|
134320
134460
|
exports2.typeDefs = {
|
|
@@ -134441,8 +134581,8 @@ var require_nopt = __commonJS({
|
|
|
134441
134581
|
data[k] = val;
|
|
134442
134582
|
}
|
|
134443
134583
|
function validateUrl(data, k, val) {
|
|
134444
|
-
val =
|
|
134445
|
-
if (!val
|
|
134584
|
+
val = URL.parse(String(val));
|
|
134585
|
+
if (!val) return false;
|
|
134446
134586
|
data[k] = val.href;
|
|
134447
134587
|
}
|
|
134448
134588
|
function validateStream(data, k, val) {
|
|
@@ -152032,6 +152172,9 @@ var require_resolveDependencies = __commonJS({
|
|
|
152032
152172
|
time = result2.newTime;
|
|
152033
152173
|
}
|
|
152034
152174
|
}
|
|
152175
|
+
if (ctx.maximumPublishedBy && (publishedBy == null || publishedBy > ctx.maximumPublishedBy)) {
|
|
152176
|
+
publishedBy = ctx.maximumPublishedBy;
|
|
152177
|
+
}
|
|
152035
152178
|
const pkgAddressesByImportersWithoutPeers = await Promise.all((0, zipWith_1.default)(async (importer, { pkgAddresses, postponedResolutionsQueue, postponedPeersResolutionQueue }) => {
|
|
152036
152179
|
const newPreferredVersions = Object.create(importer.preferredVersions);
|
|
152037
152180
|
const currentParentPkgAliases = {};
|
|
@@ -152107,7 +152250,8 @@ var require_resolveDependencies = __commonJS({
|
|
|
152107
152250
|
...importer.options,
|
|
152108
152251
|
parentPkgAliases: importer.parentPkgAliases,
|
|
152109
152252
|
pickLowestVersion: pickLowestVersion && !importer.updatePackageManifest,
|
|
152110
|
-
pinnedVersion: importer.pinnedVersion
|
|
152253
|
+
pinnedVersion: importer.pinnedVersion,
|
|
152254
|
+
publishedBy: ctx.maximumPublishedBy
|
|
152111
152255
|
}, extendedWantedDep);
|
|
152112
152256
|
if (result2.resolveDependencyResult != null && catalogLookup != null) {
|
|
152113
152257
|
result2.resolveDependencyResult.catalogLookup = {
|
|
@@ -152524,6 +152668,10 @@ var require_resolveDependencies = __commonJS({
|
|
|
152524
152668
|
if (!options.updateRequested && options.preferredVersion != null) {
|
|
152525
152669
|
wantedDependency.bareSpecifier = (0, replaceVersionInBareSpecifier_js_1.replaceVersionInBareSpecifier)(wantedDependency.bareSpecifier, options.preferredVersion);
|
|
152526
152670
|
}
|
|
152671
|
+
let publishedBy;
|
|
152672
|
+
if (options.publishedBy && (ctx.minimumReleaseAgeExclude == null || wantedDependency.alias == null || !ctx.minimumReleaseAgeExclude.includes(wantedDependency.alias))) {
|
|
152673
|
+
publishedBy = options.publishedBy;
|
|
152674
|
+
}
|
|
152527
152675
|
pkgResponse = await ctx.storeController.requestPackage(wantedDependency, {
|
|
152528
152676
|
alwaysTryWorkspacePackages: ctx.linkWorkspacePackagesDepth >= options.currentDepth,
|
|
152529
152677
|
currentPkg: currentPkg ? {
|
|
@@ -152535,7 +152683,7 @@ var require_resolveDependencies = __commonJS({
|
|
|
152535
152683
|
expectedPkg: currentPkg,
|
|
152536
152684
|
defaultTag: ctx.defaultTag,
|
|
152537
152685
|
ignoreScripts: ctx.ignoreScripts,
|
|
152538
|
-
publishedBy
|
|
152686
|
+
publishedBy,
|
|
152539
152687
|
pickLowestVersion: options.pickLowestVersion,
|
|
152540
152688
|
downloadPriority: -options.currentDepth,
|
|
152541
152689
|
lockfileDir: ctx.lockfileDir,
|
|
@@ -152923,7 +153071,9 @@ var require_resolveDependencyTree = __commonJS({
|
|
|
152923
153071
|
workspacePackages: opts.workspacePackages,
|
|
152924
153072
|
missingPeersOfChildrenByPkgId: {},
|
|
152925
153073
|
hoistPeers: autoInstallPeers || opts.dedupePeerDependents,
|
|
152926
|
-
allPeerDepNames: /* @__PURE__ */ new Set()
|
|
153074
|
+
allPeerDepNames: /* @__PURE__ */ new Set(),
|
|
153075
|
+
maximumPublishedBy: opts.minimumReleaseAge ? new Date(Date.now() - opts.minimumReleaseAge * 60 * 1e3) : void 0,
|
|
153076
|
+
minimumReleaseAgeExclude: opts.minimumReleaseAgeExclude
|
|
152927
153077
|
};
|
|
152928
153078
|
const resolveArgs = importers.map((importer) => {
|
|
152929
153079
|
const projectSnapshot = opts.wantedLockfile.importers[importer.id];
|
|
@@ -158291,6 +158441,11 @@ var require_validateModules = __commonJS({
|
|
|
158291
158441
|
}
|
|
158292
158442
|
async function purgeModulesDirsOfImporters(opts, importers) {
|
|
158293
158443
|
if (opts.confirmModulesPurge ?? true) {
|
|
158444
|
+
if (!process.stdin.isTTY) {
|
|
158445
|
+
throw new error_1.PnpmError("ABORTED_REMOVE_MODULES_DIR_NO_TTY", "Aborted removal of modules directory due to no TTY", {
|
|
158446
|
+
hint: 'If you are running pnpm in CI, set the CI environment variable to "true".'
|
|
158447
|
+
});
|
|
158448
|
+
}
|
|
158294
158449
|
const confirmed = await enquirer_1.default.prompt({
|
|
158295
158450
|
type: "confirm",
|
|
158296
158451
|
name: "question",
|
|
@@ -159043,7 +159198,9 @@ Note that in CI environments, this setting is enabled by default.`
|
|
|
159043
159198
|
resolvePeersFromWorkspaceRoot: opts.resolvePeersFromWorkspaceRoot,
|
|
159044
159199
|
supportedArchitectures: opts.supportedArchitectures,
|
|
159045
159200
|
peersSuffixMaxLength: opts.peersSuffixMaxLength,
|
|
159046
|
-
injectWorkspacePackages: opts.injectWorkspacePackages
|
|
159201
|
+
injectWorkspacePackages: opts.injectWorkspacePackages,
|
|
159202
|
+
minimumReleaseAge: opts.minimumReleaseAge,
|
|
159203
|
+
minimumReleaseAgeExclude: opts.minimumReleaseAgeExclude
|
|
159047
159204
|
});
|
|
159048
159205
|
if (!opts.include.optionalDependencies || !opts.include.devDependencies || !opts.include.dependencies) {
|
|
159049
159206
|
linkedDependenciesByProjectId = (0, map_1.default)((linkedDeps) => linkedDeps.filter((linkedDep) => !(linkedDep.dev && !opts.include.devDependencies || linkedDep.optional && !opts.include.optionalDependencies || !linkedDep.dev && !linkedDep.optional && !opts.include.dependencies)), linkedDependenciesByProjectId ?? {});
|
|
@@ -161556,6 +161713,7 @@ var require_remove3 = __commonJS({
|
|
|
161556
161713
|
var error_1 = require_lib6();
|
|
161557
161714
|
var get_context_1 = require_lib122();
|
|
161558
161715
|
var workspace_find_packages_1 = require_lib103();
|
|
161716
|
+
var workspace_manifest_writer_1 = require_lib95();
|
|
161559
161717
|
var manifest_utils_1 = require_lib65();
|
|
161560
161718
|
var store_connection_manager_1 = require_lib92();
|
|
161561
161719
|
var core_1 = require_lib167();
|
|
@@ -161699,6 +161857,10 @@ var require_remove3 = __commonJS({
|
|
|
161699
161857
|
targetDependenciesField
|
|
161700
161858
|
}, removeOpts);
|
|
161701
161859
|
await writeProjectManifest(mutationResult.updatedProject.manifest);
|
|
161860
|
+
await (0, workspace_manifest_writer_1.updateWorkspaceManifest)(opts.workspaceDir ?? opts.dir, {
|
|
161861
|
+
cleanupUnusedCatalogs: opts.cleanupUnusedCatalogs,
|
|
161862
|
+
allProjects: opts.allProjects
|
|
161863
|
+
});
|
|
161702
161864
|
}
|
|
161703
161865
|
}
|
|
161704
161866
|
});
|
|
@@ -182017,7 +182179,11 @@ var require_deploy = __commonJS({
|
|
|
182017
182179
|
}
|
|
182018
182180
|
async function handler(opts, params) {
|
|
182019
182181
|
if (!opts.workspaceDir) {
|
|
182020
|
-
|
|
182182
|
+
let hint;
|
|
182183
|
+
if (opts.rootProjectManifest?.scripts?.["deploy"] != null) {
|
|
182184
|
+
hint = 'Maybe you wanted to invoke "pnpm run deploy"';
|
|
182185
|
+
}
|
|
182186
|
+
throw new error_1.PnpmError("CANNOT_DEPLOY", "A deploy is only possible from inside a workspace", { hint });
|
|
182021
182187
|
}
|
|
182022
182188
|
const selectedProjects = Object.values(opts.selectedProjectsGraph ?? {});
|
|
182023
182189
|
if (selectedProjects.length === 0) {
|
|
@@ -182484,6 +182650,7 @@ var require_getPkgInfo = __commonJS({
|
|
|
182484
182650
|
var lockfile_utils_1 = require_lib123();
|
|
182485
182651
|
var lockfile_detect_dep_types_1 = require_lib129();
|
|
182486
182652
|
var dependency_path_1 = require_lib84();
|
|
182653
|
+
var read_package_json_1 = require_lib58();
|
|
182487
182654
|
var normalize_path_1 = __importDefault2(require_normalize_path());
|
|
182488
182655
|
function getPkgInfo(opts) {
|
|
182489
182656
|
let name;
|
|
@@ -182548,7 +182715,10 @@ var require_getPkgInfo = __commonJS({
|
|
|
182548
182715
|
} else if (depType === lockfile_detect_dep_types_1.DepType.ProdOnly) {
|
|
182549
182716
|
packageInfo.dev = false;
|
|
182550
182717
|
}
|
|
182551
|
-
return
|
|
182718
|
+
return {
|
|
182719
|
+
pkgInfo: packageInfo,
|
|
182720
|
+
readManifest: () => (0, read_package_json_1.readPackageJsonFromDirSync)(fullPackagePath)
|
|
182721
|
+
};
|
|
182552
182722
|
}
|
|
182553
182723
|
}
|
|
182554
182724
|
});
|
|
@@ -182725,7 +182895,7 @@ var require_getTree = __commonJS({
|
|
|
182725
182895
|
let resultCircular = false;
|
|
182726
182896
|
for (const alias in deps) {
|
|
182727
182897
|
const ref = deps[alias];
|
|
182728
|
-
const packageInfo = (0, getPkgInfo_js_1.getPkgInfo)({
|
|
182898
|
+
const { pkgInfo: packageInfo, readManifest } = (0, getPkgInfo_js_1.getPkgInfo)({
|
|
182729
182899
|
alias,
|
|
182730
182900
|
currentPackages: opts.currentPackages,
|
|
182731
182901
|
depTypes: opts.depTypes,
|
|
@@ -182740,7 +182910,11 @@ var require_getTree = __commonJS({
|
|
|
182740
182910
|
virtualStoreDirMaxLength: opts.virtualStoreDirMaxLength
|
|
182741
182911
|
});
|
|
182742
182912
|
let circular;
|
|
182743
|
-
const matchedSearched = opts.search?.(
|
|
182913
|
+
const matchedSearched = opts.search?.({
|
|
182914
|
+
name: packageInfo.name,
|
|
182915
|
+
version: packageInfo.version,
|
|
182916
|
+
readManifest
|
|
182917
|
+
});
|
|
182744
182918
|
let newEntry = null;
|
|
182745
182919
|
const nodeId = (0, getTreeNodeChildId_js_1.getTreeNodeChildId)({
|
|
182746
182920
|
parentId,
|
|
@@ -182797,6 +182971,9 @@ var require_getTree = __commonJS({
|
|
|
182797
182971
|
}
|
|
182798
182972
|
if (matchedSearched) {
|
|
182799
182973
|
newEntry.searched = true;
|
|
182974
|
+
if (typeof matchedSearched === "string") {
|
|
182975
|
+
newEntry.searchMessage = matchedSearched;
|
|
182976
|
+
}
|
|
182800
182977
|
}
|
|
182801
182978
|
if (!newEntry.isPeer || !opts.excludePeerDependencies || newEntry.dependencies?.length) {
|
|
182802
182979
|
resultDependencies.push(newEntry);
|
|
@@ -182937,7 +183114,7 @@ var require_buildDependenciesHierarchy = __commonJS({
|
|
|
182937
183114
|
result2[dependenciesField] = [];
|
|
182938
183115
|
for (const alias in topDeps) {
|
|
182939
183116
|
const ref = topDeps[alias];
|
|
182940
|
-
const packageInfo = (0, getPkgInfo_js_1.getPkgInfo)({
|
|
183117
|
+
const { pkgInfo: packageInfo, readManifest } = (0, getPkgInfo_js_1.getPkgInfo)({
|
|
182941
183118
|
alias,
|
|
182942
183119
|
currentPackages: currentLockfile.packages ?? {},
|
|
182943
183120
|
depTypes,
|
|
@@ -182951,7 +183128,11 @@ var require_buildDependenciesHierarchy = __commonJS({
|
|
|
182951
183128
|
virtualStoreDirMaxLength: opts.virtualStoreDirMaxLength
|
|
182952
183129
|
});
|
|
182953
183130
|
let newEntry = null;
|
|
182954
|
-
const matchedSearched = opts.search?.(
|
|
183131
|
+
const matchedSearched = opts.search?.({
|
|
183132
|
+
name: packageInfo.name,
|
|
183133
|
+
version: packageInfo.version,
|
|
183134
|
+
readManifest
|
|
183135
|
+
});
|
|
182955
183136
|
const nodeId = (0, getTreeNodeChildId_js_1.getTreeNodeChildId)({
|
|
182956
183137
|
parentId,
|
|
182957
183138
|
dep: { alias, ref },
|
|
@@ -182978,6 +183159,9 @@ var require_buildDependenciesHierarchy = __commonJS({
|
|
|
182978
183159
|
if (newEntry != null) {
|
|
182979
183160
|
if (matchedSearched) {
|
|
182980
183161
|
newEntry.searched = true;
|
|
183162
|
+
if (typeof matchedSearched === "string") {
|
|
183163
|
+
newEntry.searchMessage = matchedSearched;
|
|
183164
|
+
}
|
|
182981
183165
|
}
|
|
182982
183166
|
result2[dependenciesField].push(newEntry);
|
|
182983
183167
|
}
|
|
@@ -183002,12 +183186,19 @@ var require_buildDependenciesHierarchy = __commonJS({
|
|
|
183002
183186
|
path: pkgPath,
|
|
183003
183187
|
version: version2
|
|
183004
183188
|
};
|
|
183005
|
-
const matchedSearched = opts.search?.(
|
|
183189
|
+
const matchedSearched = opts.search?.({
|
|
183190
|
+
name: pkg.name,
|
|
183191
|
+
version: pkg.version,
|
|
183192
|
+
readManifest: () => (0, read_package_json_1.readPackageJsonFromDirSync)(pkgPath)
|
|
183193
|
+
});
|
|
183006
183194
|
if (opts.search != null && !matchedSearched)
|
|
183007
183195
|
return;
|
|
183008
183196
|
const newEntry = pkg;
|
|
183009
183197
|
if (matchedSearched) {
|
|
183010
183198
|
newEntry.searched = true;
|
|
183199
|
+
if (typeof matchedSearched === "string") {
|
|
183200
|
+
newEntry.searchMessage = matchedSearched;
|
|
183201
|
+
}
|
|
183011
183202
|
}
|
|
183012
183203
|
result2.unsavedDependencies = result2.unsavedDependencies ?? [];
|
|
183013
183204
|
result2.unsavedDependencies.push(newEntry);
|
|
@@ -183036,18 +183227,38 @@ var require_createPackagesSearcher = __commonJS({
|
|
|
183036
183227
|
var matcher_1 = require_lib17();
|
|
183037
183228
|
var npm_package_arg_1 = __importDefault2(require_npa());
|
|
183038
183229
|
var semver_12 = __importDefault2(require_semver2());
|
|
183039
|
-
function createPackagesSearcher(queries) {
|
|
183230
|
+
function createPackagesSearcher(queries, finders) {
|
|
183040
183231
|
const searchers = queries.map(parseSearchQuery).map((packageSelector) => search.bind(null, packageSelector));
|
|
183041
|
-
return (pkg) =>
|
|
183232
|
+
return (pkg) => {
|
|
183233
|
+
if (searchers.length > 0 && searchers.some((search2) => search2(pkg))) {
|
|
183234
|
+
return true;
|
|
183235
|
+
}
|
|
183236
|
+
if (finders == null)
|
|
183237
|
+
return false;
|
|
183238
|
+
const messages = [];
|
|
183239
|
+
let found = false;
|
|
183240
|
+
for (const finder of finders) {
|
|
183241
|
+
const result2 = finder(pkg);
|
|
183242
|
+
if (result2) {
|
|
183243
|
+
found = true;
|
|
183244
|
+
if (typeof result2 === "string") {
|
|
183245
|
+
messages.push(result2);
|
|
183246
|
+
}
|
|
183247
|
+
}
|
|
183248
|
+
}
|
|
183249
|
+
if (messages.length)
|
|
183250
|
+
return messages.join("\n");
|
|
183251
|
+
return found;
|
|
183252
|
+
};
|
|
183042
183253
|
}
|
|
183043
|
-
function search(packageSelector,
|
|
183044
|
-
if (!packageSelector.matchName(
|
|
183254
|
+
function search(packageSelector, { name, version: version2 }) {
|
|
183255
|
+
if (!packageSelector.matchName(name)) {
|
|
183045
183256
|
return false;
|
|
183046
183257
|
}
|
|
183047
183258
|
if (packageSelector.matchVersion == null) {
|
|
183048
183259
|
return true;
|
|
183049
183260
|
}
|
|
183050
|
-
return !
|
|
183261
|
+
return !version2.startsWith("link:") && packageSelector.matchVersion(version2);
|
|
183051
183262
|
}
|
|
183052
183263
|
function parseSearchQuery(query) {
|
|
183053
183264
|
const parsed = (0, npm_package_arg_1.default)(query);
|
|
@@ -183334,12 +183545,17 @@ ${output}`.replace(/(\n)+$/, "");
|
|
|
183334
183545
|
async function toArchyTree(getPkgColor2, entryNodes, opts) {
|
|
183335
183546
|
return Promise.all(sortPackages(entryNodes).map(async (node) => {
|
|
183336
183547
|
const nodes = await toArchyTree(getPkgColor2, node.dependencies ?? [], opts);
|
|
183548
|
+
const labelLines = [
|
|
183549
|
+
printLabel(getPkgColor2, node)
|
|
183550
|
+
];
|
|
183551
|
+
if (node.searchMessage) {
|
|
183552
|
+
labelLines.push(node.searchMessage);
|
|
183553
|
+
}
|
|
183337
183554
|
if (opts.long) {
|
|
183338
183555
|
const pkg = await (0, getPkgInfo_js_1.getPkgInfo)(node);
|
|
183339
|
-
|
|
183340
|
-
|
|
183341
|
-
|
|
183342
|
-
];
|
|
183556
|
+
if (pkg.description) {
|
|
183557
|
+
labelLines.push(pkg.description);
|
|
183558
|
+
}
|
|
183343
183559
|
if (pkg.repository) {
|
|
183344
183560
|
labelLines.push(pkg.repository);
|
|
183345
183561
|
}
|
|
@@ -183349,13 +183565,9 @@ ${output}`.replace(/(\n)+$/, "");
|
|
|
183349
183565
|
if (pkg.path) {
|
|
183350
183566
|
labelLines.push(pkg.path);
|
|
183351
183567
|
}
|
|
183352
|
-
return {
|
|
183353
|
-
label: labelLines.join("\n"),
|
|
183354
|
-
nodes
|
|
183355
|
-
};
|
|
183356
183568
|
}
|
|
183357
183569
|
return {
|
|
183358
|
-
label:
|
|
183570
|
+
label: labelLines.join("\n"),
|
|
183359
183571
|
nodes
|
|
183360
183572
|
};
|
|
183361
183573
|
}));
|
|
@@ -183541,7 +183753,7 @@ var require_lib179 = __commonJS({
|
|
|
183541
183753
|
}
|
|
183542
183754
|
}
|
|
183543
183755
|
async function searchForPackages(packages, projectPaths, opts) {
|
|
183544
|
-
const search = (0, reviewing_dependencies_hierarchy_1.createPackagesSearcher)(packages);
|
|
183756
|
+
const search = (0, reviewing_dependencies_hierarchy_1.createPackagesSearcher)(packages, opts.finders);
|
|
183545
183757
|
return Promise.all(Object.entries(await (0, reviewing_dependencies_hierarchy_1.buildDependenciesHierarchy)(projectPaths, {
|
|
183546
183758
|
depth: opts.depth,
|
|
183547
183759
|
excludePeerDependencies: opts.excludePeerDependencies,
|
|
@@ -183681,6 +183893,7 @@ var require_list2 = __commonJS({
|
|
|
183681
183893
|
exports2.help = help;
|
|
183682
183894
|
exports2.handler = handler;
|
|
183683
183895
|
exports2.render = render;
|
|
183896
|
+
var error_1 = require_lib6();
|
|
183684
183897
|
var cli_utils_1 = require_lib101();
|
|
183685
183898
|
var common_cli_options_help_1 = require_lib114();
|
|
183686
183899
|
var config_1 = require_lib20();
|
|
@@ -183710,7 +183923,8 @@ var require_list2 = __commonJS({
|
|
|
183710
183923
|
...rcOptionsTypes(),
|
|
183711
183924
|
"exclude-peers": Boolean,
|
|
183712
183925
|
"only-projects": Boolean,
|
|
183713
|
-
recursive: Boolean
|
|
183926
|
+
recursive: Boolean,
|
|
183927
|
+
"find-by": [String, Array]
|
|
183714
183928
|
});
|
|
183715
183929
|
exports2.cliOptionsTypes = cliOptionsTypes;
|
|
183716
183930
|
exports2.shorthands = {
|
|
@@ -183810,6 +184024,15 @@ var require_list2 = __commonJS({
|
|
|
183810
184024
|
});
|
|
183811
184025
|
}
|
|
183812
184026
|
async function render(prefixes, params, opts) {
|
|
184027
|
+
const finders = [];
|
|
184028
|
+
if (opts.findBy) {
|
|
184029
|
+
for (const finderName of opts.findBy) {
|
|
184030
|
+
if (opts.finders?.[finderName] == null) {
|
|
184031
|
+
throw new error_1.PnpmError("FINDER_NOT_FOUND", `No finder with name ${finderName} is found`);
|
|
184032
|
+
}
|
|
184033
|
+
finders.push(opts.finders[finderName]);
|
|
184034
|
+
}
|
|
184035
|
+
}
|
|
183813
184036
|
const listOpts = {
|
|
183814
184037
|
alwaysPrintRootPackage: opts.alwaysPrintRootPackage,
|
|
183815
184038
|
depth: opts.depth ?? 0,
|
|
@@ -183821,9 +184044,10 @@ var require_list2 = __commonJS({
|
|
|
183821
184044
|
reportAs: opts.parseable ? "parseable" : opts.json ? "json" : "tree",
|
|
183822
184045
|
showExtraneous: false,
|
|
183823
184046
|
modulesDir: opts.modulesDir,
|
|
183824
|
-
virtualStoreDirMaxLength: opts.virtualStoreDirMaxLength
|
|
184047
|
+
virtualStoreDirMaxLength: opts.virtualStoreDirMaxLength,
|
|
184048
|
+
finders
|
|
183825
184049
|
};
|
|
183826
|
-
return params.length > 0 ? (0, list_1.listForPackages)(params, prefixes, listOpts) : (0, list_1.list)(prefixes, listOpts);
|
|
184050
|
+
return params.length > 0 || listOpts.finders.length > 0 ? (0, list_1.listForPackages)(params, prefixes, listOpts) : (0, list_1.list)(prefixes, listOpts);
|
|
183827
184051
|
}
|
|
183828
184052
|
}
|
|
183829
184053
|
});
|
|
@@ -183916,7 +184140,8 @@ var require_why = __commonJS({
|
|
|
183916
184140
|
var cliOptionsTypes = () => ({
|
|
183917
184141
|
...rcOptionsTypes(),
|
|
183918
184142
|
"exclude-peers": Boolean,
|
|
183919
|
-
recursive: Boolean
|
|
184143
|
+
recursive: Boolean,
|
|
184144
|
+
"find-by": [String, Array]
|
|
183920
184145
|
});
|
|
183921
184146
|
exports2.cliOptionsTypes = cliOptionsTypes;
|
|
183922
184147
|
exports2.shorthands = {
|
|
@@ -183986,8 +184211,8 @@ For example: pnpm why babel-* eslint-*`,
|
|
|
183986
184211
|
});
|
|
183987
184212
|
}
|
|
183988
184213
|
async function handler(opts, params) {
|
|
183989
|
-
if (params.length === 0) {
|
|
183990
|
-
throw new error_1.PnpmError("MISSING_PACKAGE_NAME", "`pnpm why` requires the package name");
|
|
184214
|
+
if (params.length === 0 && opts.findBy == null) {
|
|
184215
|
+
throw new error_1.PnpmError("MISSING_PACKAGE_NAME", "`pnpm why` requires the package name or --find-by=<finder-name>");
|
|
183991
184216
|
}
|
|
183992
184217
|
return (0, list_js_1.handler)({
|
|
183993
184218
|
...opts,
|
|
@@ -187008,7 +187233,7 @@ var require_publish2 = __commonJS({
|
|
|
187008
187233
|
args.splice(index, 2);
|
|
187009
187234
|
}
|
|
187010
187235
|
}
|
|
187011
|
-
if (dirInParams
|
|
187236
|
+
if (dirInParams != null && (dirInParams.endsWith(".tgz") || dirInParams?.endsWith(".tar.gz"))) {
|
|
187012
187237
|
const { status: status2 } = (0, run_npm_1.runNpm)(opts.npmPath, ["publish", dirInParams, ...args]);
|
|
187013
187238
|
return { exitCode: status2 ?? 0 };
|
|
187014
187239
|
}
|
|
@@ -188169,7 +188394,7 @@ var require_patchCommit = __commonJS({
|
|
|
188169
188394
|
let stdout;
|
|
188170
188395
|
let stderr;
|
|
188171
188396
|
try {
|
|
188172
|
-
const result2 = await (0, safe_execa_1.default)("git", ["-c", "core.safecrlf=false", "diff", "--src-prefix=a/", "--dst-prefix=b/", "--ignore-cr-at-eol", "--irreversible-delete", "--full-index", "--no-index", "--text", "--no-ext-diff", folderAN, folderBN], {
|
|
188397
|
+
const result2 = await (0, safe_execa_1.default)("git", ["-c", "core.safecrlf=false", "diff", "--src-prefix=a/", "--dst-prefix=b/", "--ignore-cr-at-eol", "--irreversible-delete", "--full-index", "--no-index", "--text", "--no-ext-diff", "--no-color", folderAN, folderBN], {
|
|
188173
188398
|
cwd: process.cwd(),
|
|
188174
188399
|
env: {
|
|
188175
188400
|
...process.env,
|