libnpmexec 6.0.2 → 7.0.0-pre.0
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/lib/index.js +5 -3
- package/package.json +16 -10
package/lib/index.js
CHANGED
|
@@ -245,9 +245,12 @@ const exec = async (opts) => {
|
|
|
245
245
|
|
|
246
246
|
if (add.length) {
|
|
247
247
|
if (!yes) {
|
|
248
|
+
const missingPackages = add.map(a => `${a.replace(/@$/, '')}`)
|
|
248
249
|
// set -n to always say no
|
|
249
250
|
if (yes === false) {
|
|
250
|
-
|
|
251
|
+
// Error message lists missing package(s) when process is canceled
|
|
252
|
+
/* eslint-disable-next-line max-len */
|
|
253
|
+
throw new Error(`npx canceled due to missing packages and no YES option: ${JSON.stringify(missingPackages)}`)
|
|
251
254
|
}
|
|
252
255
|
|
|
253
256
|
if (noTTY() || ciInfo.isCI) {
|
|
@@ -257,8 +260,7 @@ const exec = async (opts) => {
|
|
|
257
260
|
add.map((pkg) => pkg.replace(/@$/, '')).join(', ')
|
|
258
261
|
}`)
|
|
259
262
|
} else {
|
|
260
|
-
const addList =
|
|
261
|
-
.join('\n') + '\n'
|
|
263
|
+
const addList = missingPackages.join('\n') + '\n'
|
|
262
264
|
const prompt = `Need to install the following packages:\n${
|
|
263
265
|
addList
|
|
264
266
|
}Ok to proceed? `
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "libnpmexec",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "7.0.0-pre.0",
|
|
4
4
|
"files": [
|
|
5
5
|
"bin/",
|
|
6
6
|
"lib/"
|
|
7
7
|
],
|
|
8
8
|
"main": "lib/index.js",
|
|
9
9
|
"engines": {
|
|
10
|
-
"node": "^
|
|
10
|
+
"node": "^16.14.0 || >=18.0.0"
|
|
11
11
|
},
|
|
12
12
|
"description": "npm exec (npx) programmatic API",
|
|
13
13
|
"repository": {
|
|
@@ -51,20 +51,20 @@
|
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"@npmcli/eslint-config": "^4.0.0",
|
|
53
53
|
"@npmcli/mock-registry": "^1.0.0",
|
|
54
|
-
"@npmcli/template-oss": "4.
|
|
54
|
+
"@npmcli/template-oss": "4.18.0",
|
|
55
55
|
"bin-links": "^4.0.1",
|
|
56
56
|
"chalk": "^5.2.0",
|
|
57
57
|
"just-extend": "^6.2.0",
|
|
58
58
|
"just-safe-set": "^4.2.1",
|
|
59
|
-
"tap": "^16.3.
|
|
59
|
+
"tap": "^16.3.8"
|
|
60
60
|
},
|
|
61
61
|
"dependencies": {
|
|
62
|
-
"@npmcli/arborist": "^
|
|
63
|
-
"@npmcli/run-script": "^
|
|
62
|
+
"@npmcli/arborist": "^7.0.0-pre.0",
|
|
63
|
+
"@npmcli/run-script": "^7.0.1",
|
|
64
64
|
"ci-info": "^3.7.1",
|
|
65
|
-
"npm-package-arg": "^
|
|
65
|
+
"npm-package-arg": "^11.0.0",
|
|
66
66
|
"npmlog": "^7.0.1",
|
|
67
|
-
"pacote": "^
|
|
67
|
+
"pacote": "^17.0.4",
|
|
68
68
|
"proc-log": "^3.0.0",
|
|
69
69
|
"read": "^2.0.0",
|
|
70
70
|
"read-package-json-fast": "^3.0.2",
|
|
@@ -73,7 +73,13 @@
|
|
|
73
73
|
},
|
|
74
74
|
"templateOSS": {
|
|
75
75
|
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
|
|
76
|
-
"version": "4.
|
|
77
|
-
"content": "../../scripts/template-oss/index.js"
|
|
76
|
+
"version": "4.18.0",
|
|
77
|
+
"content": "../../scripts/template-oss/index.js",
|
|
78
|
+
"ciVersions": [
|
|
79
|
+
"16.14.0",
|
|
80
|
+
"16.x",
|
|
81
|
+
"18.0.0",
|
|
82
|
+
"18.x"
|
|
83
|
+
]
|
|
78
84
|
}
|
|
79
85
|
}
|