diff --git a/commands/add/index.js b/commands/add/index.js index b173ca1e8e..347f262d3e 100644 --- a/commands/add/index.js +++ b/commands/add/index.js @@ -4,7 +4,7 @@ const dedent = require("dedent"); const npa = require("npm-package-arg"); const pMap = require("p-map"); const path = require("path"); -const getManifest = require("pacote/manifest"); +const getManifest = require("@evocateur/pacote/manifest"); const semver = require("semver"); const Command = require("@lerna/command"); diff --git a/commands/add/package.json b/commands/add/package.json index 8d05d4bd79..0725d1a29e 100644 --- a/commands/add/package.json +++ b/commands/add/package.json @@ -33,6 +33,7 @@ "test": "echo \"Run tests from root\" && exit 1" }, "dependencies": { + "@evocateur/pacote": "^9.6.0", "@lerna/bootstrap": "file:../bootstrap", "@lerna/command": "file:../../core/command", "@lerna/filter-options": "file:../../core/filter-options", @@ -41,7 +42,6 @@ "dedent": "^0.7.0", "npm-package-arg": "^6.1.0", "p-map": "^1.2.0", - "pacote": "^9.5.0", "semver": "^5.5.0" } } diff --git a/commands/create/__tests__/create-command.test.js b/commands/create/__tests__/create-command.test.js index c3ea868814..f76526c002 100644 --- a/commands/create/__tests__/create-command.test.js +++ b/commands/create/__tests__/create-command.test.js @@ -1,6 +1,6 @@ "use strict"; -jest.mock("pacote/manifest"); +jest.mock("@evocateur/pacote/manifest"); const fs = require("fs-extra"); const path = require("path"); @@ -8,7 +8,7 @@ const execa = require("execa"); const slash = require("slash"); // mocked modules -const getManifest = require("pacote/manifest"); +const getManifest = require("@evocateur/pacote/manifest"); // helpers const initFixture = require("@lerna-test/init-fixture")(__dirname); diff --git a/commands/create/index.js b/commands/create/index.js index a99c82ccea..5e9fccf19e 100644 --- a/commands/create/index.js +++ b/commands/create/index.js @@ -7,7 +7,7 @@ const { URL } = require("whatwg-url"); const camelCase = require("camelcase"); const dedent = require("dedent"); const initPackageJson = require("pify")(require("init-package-json")); -const getManifest = require("pacote/manifest"); +const getManifest = require("@evocateur/pacote/manifest"); const npa = require("npm-package-arg"); const pReduce = require("p-reduce"); const slash = require("slash"); diff --git a/commands/create/package.json b/commands/create/package.json index 86d2359467..70604bf904 100644 --- a/commands/create/package.json +++ b/commands/create/package.json @@ -33,6 +33,7 @@ "test": "echo \"Run tests from root\" && exit 1" }, "dependencies": { + "@evocateur/pacote": "^9.6.0", "@lerna/child-process": "file:../../core/child-process", "@lerna/command": "file:../../core/command", "@lerna/npm-conf": "file:../../utils/npm-conf", @@ -44,7 +45,6 @@ "init-package-json": "^1.10.3", "npm-package-arg": "^6.1.0", "p-reduce": "^1.0.0", - "pacote": "^9.5.0", "pify": "^3.0.0", "semver": "^5.5.0", "slash": "^1.0.0", diff --git a/commands/publish/__tests__/get-npm-username.test.js b/commands/publish/__tests__/get-npm-username.test.js index 774b05e582..b14a3e44d2 100644 --- a/commands/publish/__tests__/get-npm-username.test.js +++ b/commands/publish/__tests__/get-npm-username.test.js @@ -1,8 +1,8 @@ "use strict"; -jest.mock("npm-registry-fetch"); +jest.mock("@evocateur/npm-registry-fetch"); -const fetch = require("npm-registry-fetch"); +const fetch = require("@evocateur/npm-registry-fetch"); const loggingOutput = require("@lerna-test/logging-output"); const getNpmUsername = require("../lib/get-npm-username"); diff --git a/commands/publish/__tests__/get-unpublished-packages.test.js b/commands/publish/__tests__/get-unpublished-packages.test.js index 86306237ab..a122593021 100644 --- a/commands/publish/__tests__/get-unpublished-packages.test.js +++ b/commands/publish/__tests__/get-unpublished-packages.test.js @@ -1,9 +1,9 @@ "use strict"; -jest.mock("pacote/packument"); +jest.mock("@evocateur/pacote/packument"); // mocked module(s) -const getPackument = require("pacote/packument"); +const getPackument = require("@evocateur/pacote/packument"); // helpers const PackageGraph = require("@lerna/package-graph"); diff --git a/commands/publish/__tests__/verify-npm-package-access.test.js b/commands/publish/__tests__/verify-npm-package-access.test.js index 884da1fb3d..3a4dcc3ec2 100644 --- a/commands/publish/__tests__/verify-npm-package-access.test.js +++ b/commands/publish/__tests__/verify-npm-package-access.test.js @@ -1,8 +1,8 @@ "use strict"; -jest.mock("libnpmaccess"); +jest.mock("@evocateur/libnpmaccess"); -const access = require("libnpmaccess"); +const access = require("@evocateur/libnpmaccess"); const { getPackages } = require("@lerna/project"); const loggingOutput = require("@lerna-test/logging-output"); const initFixture = require("@lerna-test/init-fixture")(__dirname); diff --git a/commands/publish/lib/get-npm-username.js b/commands/publish/lib/get-npm-username.js index e4e9f42390..836cdb2a44 100644 --- a/commands/publish/lib/get-npm-username.js +++ b/commands/publish/lib/get-npm-username.js @@ -1,6 +1,6 @@ "use strict"; -const fetch = require("npm-registry-fetch"); +const fetch = require("@evocateur/npm-registry-fetch"); const pulseTillDone = require("@lerna/pulse-till-done"); const ValidationError = require("@lerna/validation-error"); const FetchConfig = require("./fetch-config"); diff --git a/commands/publish/lib/get-unpublished-packages.js b/commands/publish/lib/get-unpublished-packages.js index da9095ea20..ed1431a671 100644 --- a/commands/publish/lib/get-unpublished-packages.js +++ b/commands/publish/lib/get-unpublished-packages.js @@ -2,7 +2,7 @@ const log = require("npmlog"); const pMap = require("p-map"); -const getPackument = require("pacote/packument"); +const getPackument = require("@evocateur/pacote/packument"); module.exports = getUnpublishedPackages; diff --git a/commands/publish/lib/verify-npm-package-access.js b/commands/publish/lib/verify-npm-package-access.js index b90bb81c4d..a8f7aa8221 100644 --- a/commands/publish/lib/verify-npm-package-access.js +++ b/commands/publish/lib/verify-npm-package-access.js @@ -1,6 +1,6 @@ "use strict"; -const access = require("libnpmaccess"); +const access = require("@evocateur/libnpmaccess"); const pulseTillDone = require("@lerna/pulse-till-done"); const ValidationError = require("@lerna/validation-error"); const FetchConfig = require("./fetch-config"); diff --git a/commands/publish/package.json b/commands/publish/package.json index 4c452ab6ba..9ddd3d6692 100644 --- a/commands/publish/package.json +++ b/commands/publish/package.json @@ -34,6 +34,9 @@ "test": "echo \"Run tests from root\" && exit 1" }, "dependencies": { + "@evocateur/libnpmaccess": "^3.1.0", + "@evocateur/npm-registry-fetch": "^3.9.1", + "@evocateur/pacote": "^9.6.0", "@lerna/check-working-tree": "file:../../utils/check-working-tree", "@lerna/child-process": "file:../../core/child-process", "@lerna/collect-updates": "file:../../utils/collect-updates", @@ -54,14 +57,11 @@ "@lerna/version": "file:../version", "figgy-pudding": "^3.5.1", "fs-extra": "^7.0.0", - "libnpmaccess": "^3.0.1", "npm-package-arg": "^6.1.0", - "npm-registry-fetch": "^3.9.0", "npmlog": "^4.1.2", "p-finally": "^1.0.0", "p-map": "^1.2.0", "p-pipe": "^1.2.0", - "pacote": "^9.5.0", "semver": "^5.5.0" } } diff --git a/core/cli/__tests__/core-cli.test.js b/core/cli/__tests__/core-cli.test.js index 82341745e8..d6edca46f7 100644 --- a/core/cli/__tests__/core-cli.test.js +++ b/core/cli/__tests__/core-cli.test.js @@ -164,7 +164,7 @@ describe("core-cli", () => { const spy = jest.spyOn(cli, "exit"); cli.command("errname", "a string code", {}, async () => { - const err = new Error("npm-registry-fetch"); + const err = new Error("kersplode"); err.code = "E401"; throw err; }); @@ -175,7 +175,7 @@ describe("core-cli", () => { expect(spy).toHaveBeenLastCalledWith( 1, expect.objectContaining({ - message: "npm-registry-fetch", + message: "kersplode", }) ); }); diff --git a/package-lock.json b/package-lock.json index f818ad2f0e..b0e89b8635 100644 --- a/package-lock.json +++ b/package-lock.json @@ -178,6 +178,112 @@ "minimist": "^1.2.0" } }, + "@evocateur/libnpmaccess": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@evocateur/libnpmaccess/-/libnpmaccess-3.1.0.tgz", + "integrity": "sha512-bfrqZ0v+Il5TJBsgF2oyepeJg34K2pBItapzP+UT1QMIGpUh/Zc1pQql4jrafamZTqP3ZvdJxaElat8B5K3ICA==", + "requires": { + "@evocateur/npm-registry-fetch": "^3.9.1", + "aproba": "^2.0.0", + "figgy-pudding": "^3.5.1", + "get-stream": "^4.0.0", + "npm-package-arg": "^6.1.0" + }, + "dependencies": { + "aproba": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", + "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==" + } + } + }, + "@evocateur/libnpmpublish": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@evocateur/libnpmpublish/-/libnpmpublish-1.2.0.tgz", + "integrity": "sha512-sezhX9FSnPIyrBBvxVocVJVO1uIWPczf6rOmUZSntCWfQMraO8pWTFlDJbroFqPbEqFFHf3eyw8NQ0Eb7OLd1g==", + "requires": { + "@evocateur/npm-registry-fetch": "^3.9.1", + "aproba": "^2.0.0", + "figgy-pudding": "^3.5.1", + "get-stream": "^4.0.0", + "lodash.clonedeep": "^4.5.0", + "normalize-package-data": "^2.4.0", + "npm-package-arg": "^6.1.0", + "semver": "^5.5.1", + "ssri": "^6.0.1" + }, + "dependencies": { + "aproba": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", + "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==" + } + } + }, + "@evocateur/npm-registry-fetch": { + "version": "3.9.1", + "resolved": "https://registry.npmjs.org/@evocateur/npm-registry-fetch/-/npm-registry-fetch-3.9.1.tgz", + "integrity": "sha512-6v1bHbcAypQ+te/1RGSNL4JkK6mcMtcZrUusqo5iKRtYSAig9UJXlOaCcBR+eLywt2DQMNpEwAj24jwWDX5G/w==", + "requires": { + "JSONStream": "^1.3.4", + "bluebird": "^3.5.1", + "figgy-pudding": "^3.4.1", + "lru-cache": "^4.1.3", + "make-fetch-happen": "^4.0.1", + "npm-package-arg": "^6.1.0", + "safe-buffer": "^5.1.2" + }, + "dependencies": { + "lru-cache": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", + "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", + "requires": { + "pseudomap": "^1.0.2", + "yallist": "^2.1.2" + } + }, + "yallist": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", + "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=" + } + } + }, + "@evocateur/pacote": { + "version": "9.6.0", + "resolved": "https://registry.npmjs.org/@evocateur/pacote/-/pacote-9.6.0.tgz", + "integrity": "sha512-nKx8EPxXhzqNfePbqC6603z7Kkf6GBS2q+SNGtBS/bCgS5Q+p3OVR6MXKOkpvC3WHse98W2WLu8QaV9axtfxyw==", + "requires": { + "@evocateur/npm-registry-fetch": "^3.9.1", + "bluebird": "^3.5.3", + "cacache": "^11.3.2", + "figgy-pudding": "^3.5.1", + "get-stream": "^4.1.0", + "glob": "^7.1.3", + "lru-cache": "^5.1.1", + "make-fetch-happen": "^4.0.1", + "minimatch": "^3.0.4", + "minipass": "^2.3.5", + "mississippi": "^3.0.0", + "mkdirp": "^0.5.1", + "normalize-package-data": "^2.4.0", + "npm-package-arg": "^6.1.0", + "npm-packlist": "^1.1.12", + "npm-pick-manifest": "^2.2.3", + "osenv": "^0.1.5", + "promise-inflight": "^1.0.1", + "promise-retry": "^1.1.1", + "protoduck": "^5.0.1", + "rimraf": "^2.6.2", + "safe-buffer": "^5.1.2", + "semver": "^5.6.0", + "ssri": "^6.0.1", + "tar": "^4.4.8", + "unique-filename": "^1.1.1", + "which": "^1.3.1" + } + }, "@jest/console": { "version": "24.7.1", "resolved": "https://registry.npmjs.org/@jest/console/-/console-24.7.1.tgz", @@ -676,6 +782,7 @@ "@lerna/add": { "version": "file:commands/add", "requires": { + "@evocateur/pacote": "^9.6.0", "@lerna/bootstrap": "file:commands/bootstrap", "@lerna/command": "file:core/command", "@lerna/filter-options": "file:core/filter-options", @@ -684,7 +791,6 @@ "dedent": "^0.7.0", "npm-package-arg": "^6.1.0", "p-map": "^1.2.0", - "pacote": "^9.5.0", "semver": "^5.5.0" } }, @@ -824,6 +930,7 @@ "@lerna/create": { "version": "file:commands/create", "requires": { + "@evocateur/pacote": "^9.6.0", "@lerna/child-process": "file:core/child-process", "@lerna/command": "file:core/command", "@lerna/npm-conf": "file:utils/npm-conf", @@ -835,7 +942,6 @@ "init-package-json": "^1.10.3", "npm-package-arg": "^6.1.0", "p-reduce": "^1.0.0", - "pacote": "^9.5.0", "pify": "^3.0.0", "semver": "^5.5.0", "slash": "^1.0.0", @@ -1006,10 +1112,10 @@ "@lerna/npm-dist-tag": { "version": "file:utils/npm-dist-tag", "requires": { + "@evocateur/npm-registry-fetch": "^3.9.1", "@lerna/otplease": "file:core/otplease", "figgy-pudding": "^3.5.1", "npm-package-arg": "^6.1.0", - "npm-registry-fetch": "^3.9.0", "npmlog": "^4.1.2" } }, @@ -1028,11 +1134,11 @@ "@lerna/npm-publish": { "version": "file:utils/npm-publish", "requires": { + "@evocateur/libnpmpublish": "^1.2.0", "@lerna/otplease": "file:core/otplease", "@lerna/run-lifecycle": "file:utils/run-lifecycle", "figgy-pudding": "^3.5.1", "fs-extra": "^7.0.0", - "libnpmpublish": "^1.1.1", "npm-package-arg": "^6.1.0", "npmlog": "^4.1.2", "pify": "^3.0.0", @@ -1124,6 +1230,9 @@ "@lerna/publish": { "version": "file:commands/publish", "requires": { + "@evocateur/libnpmaccess": "^3.1.0", + "@evocateur/npm-registry-fetch": "^3.9.1", + "@evocateur/pacote": "^9.6.0", "@lerna/check-working-tree": "file:utils/check-working-tree", "@lerna/child-process": "file:core/child-process", "@lerna/collect-updates": "file:utils/collect-updates", @@ -1144,14 +1253,11 @@ "@lerna/version": "file:commands/version", "figgy-pudding": "^3.5.1", "fs-extra": "^7.0.0", - "libnpmaccess": "^3.0.1", "npm-package-arg": "^6.1.0", - "npm-registry-fetch": "^3.9.0", "npmlog": "^4.1.2", "p-finally": "^1.0.0", "p-map": "^1.2.0", "p-pipe": "^1.2.0", - "pacote": "^9.5.0", "semver": "^5.5.0" } }, @@ -6008,47 +6114,6 @@ "type-check": "~0.3.2" } }, - "libnpmaccess": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/libnpmaccess/-/libnpmaccess-3.0.1.tgz", - "integrity": "sha512-RlZ7PNarCBt+XbnP7R6PoVgOq9t+kou5rvhaInoNibhPO7eMlRfS0B8yjatgn2yaHIwWNyoJDolC/6Lc5L/IQA==", - "requires": { - "aproba": "^2.0.0", - "get-stream": "^4.0.0", - "npm-package-arg": "^6.1.0", - "npm-registry-fetch": "^3.8.0" - }, - "dependencies": { - "aproba": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", - "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==" - } - } - }, - "libnpmpublish": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/libnpmpublish/-/libnpmpublish-1.1.1.tgz", - "integrity": "sha512-nefbvJd/wY38zdt+b9SHL6171vqBrMtZ56Gsgfd0duEKb/pB8rDT4/ObUQLrHz1tOfht1flt2zM+UGaemzAG5g==", - "requires": { - "aproba": "^2.0.0", - "figgy-pudding": "^3.5.1", - "get-stream": "^4.0.0", - "lodash.clonedeep": "^4.5.0", - "normalize-package-data": "^2.4.0", - "npm-package-arg": "^6.1.0", - "npm-registry-fetch": "^3.8.0", - "semver": "^5.5.1", - "ssri": "^6.0.1" - }, - "dependencies": { - "aproba": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", - "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==" - } - } - }, "load-json-file": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz", @@ -6652,35 +6717,6 @@ "semver": "^5.4.1" } }, - "npm-registry-fetch": { - "version": "3.9.0", - "resolved": "https://registry.npmjs.org/npm-registry-fetch/-/npm-registry-fetch-3.9.0.tgz", - "integrity": "sha512-srwmt8YhNajAoSAaDWndmZgx89lJwIZ1GWxOuckH4Coek4uHv5S+o/l9FLQe/awA+JwTnj4FJHldxhlXdZEBmw==", - "requires": { - "JSONStream": "^1.3.4", - "bluebird": "^3.5.1", - "figgy-pudding": "^3.4.1", - "lru-cache": "^4.1.3", - "make-fetch-happen": "^4.0.1", - "npm-package-arg": "^6.1.0" - }, - "dependencies": { - "lru-cache": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", - "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", - "requires": { - "pseudomap": "^1.0.2", - "yallist": "^2.1.2" - } - }, - "yallist": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", - "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=" - } - } - }, "npm-run-path": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", @@ -6986,40 +7022,6 @@ "p-reduce": "^1.0.0" } }, - "pacote": { - "version": "9.5.0", - "resolved": "https://registry.npmjs.org/pacote/-/pacote-9.5.0.tgz", - "integrity": "sha512-aUplXozRbzhaJO48FaaeClmN+2Mwt741MC6M3bevIGZwdCaP7frXzbUOfOWa91FPHoLITzG0hYaKY363lxO3bg==", - "requires": { - "bluebird": "^3.5.3", - "cacache": "^11.3.2", - "figgy-pudding": "^3.5.1", - "get-stream": "^4.1.0", - "glob": "^7.1.3", - "lru-cache": "^5.1.1", - "make-fetch-happen": "^4.0.1", - "minimatch": "^3.0.4", - "minipass": "^2.3.5", - "mississippi": "^3.0.0", - "mkdirp": "^0.5.1", - "normalize-package-data": "^2.4.0", - "npm-package-arg": "^6.1.0", - "npm-packlist": "^1.1.12", - "npm-pick-manifest": "^2.2.3", - "npm-registry-fetch": "^3.8.0", - "osenv": "^0.1.5", - "promise-inflight": "^1.0.1", - "promise-retry": "^1.1.1", - "protoduck": "^5.0.1", - "rimraf": "^2.6.2", - "safe-buffer": "^5.1.2", - "semver": "^5.6.0", - "ssri": "^6.0.1", - "tar": "^4.4.8", - "unique-filename": "^1.1.1", - "which": "^1.3.1" - } - }, "parallel-transform": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/parallel-transform/-/parallel-transform-1.1.0.tgz", diff --git a/utils/npm-dist-tag/__tests__/npm-dist-tag.test.js b/utils/npm-dist-tag/__tests__/npm-dist-tag.test.js index a7d3ad203d..bf19502b03 100644 --- a/utils/npm-dist-tag/__tests__/npm-dist-tag.test.js +++ b/utils/npm-dist-tag/__tests__/npm-dist-tag.test.js @@ -1,10 +1,10 @@ "use strict"; -jest.mock("npm-registry-fetch"); +jest.mock("@evocateur/npm-registry-fetch"); jest.mock("@lerna/otplease", () => (cb, opts) => Promise.resolve(cb(opts))); // mocked modules -const fetch = require("npm-registry-fetch"); +const fetch = require("@evocateur/npm-registry-fetch"); // file under test const npmDistTag = require(".."); diff --git a/utils/npm-dist-tag/npm-dist-tag.js b/utils/npm-dist-tag/npm-dist-tag.js index 70497d70dc..1dcb3e1f95 100644 --- a/utils/npm-dist-tag/npm-dist-tag.js +++ b/utils/npm-dist-tag/npm-dist-tag.js @@ -2,7 +2,7 @@ const log = require("npmlog"); const npa = require("npm-package-arg"); -const fetch = require("npm-registry-fetch"); +const fetch = require("@evocateur/npm-registry-fetch"); const figgyPudding = require("figgy-pudding"); const otplease = require("@lerna/otplease"); diff --git a/utils/npm-dist-tag/package.json b/utils/npm-dist-tag/package.json index acbb8094c1..3941a85943 100644 --- a/utils/npm-dist-tag/package.json +++ b/utils/npm-dist-tag/package.json @@ -32,10 +32,10 @@ "test": "echo \"Run tests from root\" && exit 1" }, "dependencies": { + "@evocateur/npm-registry-fetch": "^3.9.1", "@lerna/otplease": "file:../../core/otplease", "figgy-pudding": "^3.5.1", "npm-package-arg": "^6.1.0", - "npm-registry-fetch": "^3.9.0", "npmlog": "^4.1.2" } } diff --git a/utils/npm-publish/__tests__/npm-publish.test.js b/utils/npm-publish/__tests__/npm-publish.test.js index 066c277c24..394fa31800 100644 --- a/utils/npm-publish/__tests__/npm-publish.test.js +++ b/utils/npm-publish/__tests__/npm-publish.test.js @@ -3,12 +3,12 @@ jest.mock("@lerna/run-lifecycle"); jest.mock("@lerna/otplease"); jest.mock("read-package-json"); -jest.mock("libnpmpublish"); +jest.mock("@evocateur/libnpmpublish"); jest.mock("fs-extra"); // mocked modules const fs = require("fs-extra"); -const { publish } = require("libnpmpublish"); +const { publish } = require("@evocateur/libnpmpublish"); const readJSON = require("read-package-json"); const runLifecycle = require("@lerna/run-lifecycle"); const otplease = require("@lerna/otplease"); @@ -27,7 +27,7 @@ describe("npm-publish", () => { const mockManifest = { _normalized: true }; fs.readFile.mockName("fs.readFile").mockResolvedValue(mockTarData); - publish.mockName("libnpmpublish").mockResolvedValue(); + publish.mockName("@evocateur/libnpmpublish").mockResolvedValue(); readJSON.mockName("read-package-json").mockImplementation((file, cb) => cb(null, mockManifest)); runLifecycle.mockName("@lerna/run-lifecycle").mockResolvedValue(); otplease.mockName("@lerna/otplease").mockImplementation((cb, opts) => Promise.resolve(cb(opts))); diff --git a/utils/npm-publish/npm-publish.js b/utils/npm-publish/npm-publish.js index 741bdd4411..ee6ad133e6 100644 --- a/utils/npm-publish/npm-publish.js +++ b/utils/npm-publish/npm-publish.js @@ -3,7 +3,7 @@ const fs = require("fs-extra"); const path = require("path"); const log = require("npmlog"); -const { publish } = require("libnpmpublish"); +const { publish } = require("@evocateur/libnpmpublish"); const pify = require("pify"); const readJSON = require("read-package-json"); const figgyPudding = require("figgy-pudding"); diff --git a/utils/npm-publish/package.json b/utils/npm-publish/package.json index c7cf929df3..ae95b0ec7b 100644 --- a/utils/npm-publish/package.json +++ b/utils/npm-publish/package.json @@ -31,11 +31,11 @@ "test": "echo \"Run tests from root\" && exit 1" }, "dependencies": { + "@evocateur/libnpmpublish": "^1.2.0", "@lerna/otplease": "file:../../core/otplease", "@lerna/run-lifecycle": "file:../run-lifecycle", "figgy-pudding": "^3.5.1", "fs-extra": "^7.0.0", - "libnpmpublish": "^1.1.1", "npm-package-arg": "^6.1.0", "npmlog": "^4.1.2", "pify": "^3.0.0",