Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Karrys <luke@lukekarrys.com>2022-09-29 01:14:34 +0300
committerLuke Karrys <luke@lukekarrys.com>2022-09-29 02:20:41 +0300
commit247f55762a9953939750ce349a1ec7fdd583b47e (patch)
tree4cb11460d984d56b3f337a77e3150c299fc62563
parent7e6b8244b0eef9ee60e293859f4147e577cb2f3b (diff)
deps: npm-package-arg@9.1.2lk/npm-package-arg-9.1.1
Fixes #4994
-rw-r--r--node_modules/npm-package-arg/lib/npa.js6
-rw-r--r--node_modules/npm-package-arg/package.json26
-rw-r--r--package-lock.json8
-rw-r--r--package.json2
4 files changed, 28 insertions, 14 deletions
diff --git a/node_modules/npm-package-arg/lib/npa.js b/node_modules/npm-package-arg/lib/npa.js
index 61fee0783..cd1932b0b 100644
--- a/node_modules/npm-package-arg/lib/npa.js
+++ b/node_modules/npm-package-arg/lib/npa.js
@@ -241,8 +241,10 @@ function fromFile (res, where) {
rawNoPrefix = rawSpec.replace(/^file:/, '')
}
// turn file:/../foo into file:../foo
- if (/^\/\.\.?(\/|$)/.test(rawNoPrefix)) {
- const rawSpec = res.rawSpec.replace(/^file:\//, 'file:')
+ // for 1, 2 or 3 leading slashes since we attempted
+ // in the previous step to make it a file protocol url with a leading slash
+ if (/^\/{1,3}\.\.?(\/|$)/.test(rawNoPrefix)) {
+ const rawSpec = res.rawSpec.replace(/^file:\/{1,3}/, 'file:')
resolvedUrl = new url.URL(rawSpec, `file://${path.resolve(where)}/`)
specUrl = new url.URL(rawSpec)
rawNoPrefix = rawSpec.replace(/^file:/, '')
diff --git a/node_modules/npm-package-arg/package.json b/node_modules/npm-package-arg/package.json
index b9729db5d..eddc6bbbb 100644
--- a/node_modules/npm-package-arg/package.json
+++ b/node_modules/npm-package-arg/package.json
@@ -1,6 +1,6 @@
{
"name": "npm-package-arg",
- "version": "9.1.0",
+ "version": "9.1.2",
"description": "Parse the things that can be arguments to `npm install`",
"main": "./lib/npa.js",
"directories": {
@@ -18,13 +18,10 @@
},
"devDependencies": {
"@npmcli/eslint-config": "^3.0.1",
- "@npmcli/template-oss": "3.5.0",
+ "@npmcli/template-oss": "4.3.2",
"tap": "^16.0.1"
},
"scripts": {
- "preversion": "npm test",
- "postversion": "npm publish",
- "prepublishOnly": "git push origin --follow-tags",
"test": "tap",
"snap": "tap",
"npmclilint": "npmcli-lint",
@@ -49,10 +46,25 @@
"node": "^12.13.0 || ^14.15.0 || >=16.0.0"
},
"tap": {
- "branches": 97
+ "branches": 97,
+ "nyc-arg": [
+ "--exclude",
+ "tap-snapshots/**"
+ ]
},
"templateOSS": {
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
- "version": "3.5.0"
+ "version": "4.3.2",
+ "releaseBranches": [
+ "v9"
+ ],
+ "ciVersions": [
+ "12.13.0",
+ "12.x",
+ "14.15.0",
+ "14.x",
+ "16.0.0",
+ "16.x"
+ ]
}
}
diff --git a/package-lock.json b/package-lock.json
index 43f364e27..2441009d9 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -135,7 +135,7 @@
"nopt": "^6.0.0",
"npm-audit-report": "^3.0.0",
"npm-install-checks": "^5.0.0",
- "npm-package-arg": "^9.1.0",
+ "npm-package-arg": "^9.1.2",
"npm-pick-manifest": "^7.0.2",
"npm-profile": "^6.2.0",
"npm-registry-fetch": "^13.3.1",
@@ -8010,9 +8010,9 @@
"license": "ISC"
},
"node_modules/npm-package-arg": {
- "version": "9.1.0",
- "resolved": "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-9.1.0.tgz",
- "integrity": "sha512-4J0GL+u2Nh6OnhvUKXRr2ZMG4lR8qtLp+kv7UiV00Y+nGiSxtttCyIRHCt5L5BNkXQld/RceYItau3MDOoGiBw==",
+ "version": "9.1.2",
+ "resolved": "https://registry.npmjs.org/npm-package-arg/-/npm-package-arg-9.1.2.tgz",
+ "integrity": "sha512-pzd9rLEx4TfNJkovvlBSLGhq31gGu2QDexFPWT19yCDh0JgnRhlBLNo5759N0AJmBk+kQ9Y/hXoLnlgFD+ukmg==",
"inBundle": true,
"dependencies": {
"hosted-git-info": "^5.0.0",
diff --git a/package.json b/package.json
index 7d0be9883..250f519e1 100644
--- a/package.json
+++ b/package.json
@@ -100,7 +100,7 @@
"nopt": "^6.0.0",
"npm-audit-report": "^3.0.0",
"npm-install-checks": "^5.0.0",
- "npm-package-arg": "^9.1.0",
+ "npm-package-arg": "^9.1.2",
"npm-pick-manifest": "^7.0.2",
"npm-profile": "^6.2.0",
"npm-registry-fetch": "^13.3.1",