diff options
author | Michael Perrotte <mike@npmjs.com> | 2020-02-21 00:57:21 +0300 |
---|---|---|
committer | isaacs <i@izs.me> | 2020-05-08 04:11:52 +0300 |
commit | b9e8be48f931ce8ead3e5d4ac7b6cb7b187ac5b7 (patch) | |
tree | 04985321a2402391558de7b258c9935dde2adbef /lib | |
parent | d7604fac09f1cdf2b177147c1376883a5588bb29 (diff) |
chore: update/removed usages of libnpm
Diffstat (limited to 'lib')
-rw-r--r-- | lib/access.js | 2 | ||||
-rw-r--r-- | lib/audit.js | 2 | ||||
-rw-r--r-- | lib/auth/legacy.js | 2 | ||||
-rw-r--r-- | lib/auth/sso.js | 2 | ||||
-rw-r--r-- | lib/deprecate.js | 4 | ||||
-rw-r--r-- | lib/dist-tag.js | 4 | ||||
-rw-r--r-- | lib/hook.js | 2 | ||||
-rw-r--r-- | lib/install/action/extract-worker.js | 2 | ||||
-rw-r--r-- | lib/logout.js | 2 | ||||
-rw-r--r-- | lib/org.js | 2 | ||||
-rw-r--r-- | lib/outdated.js | 4 | ||||
-rw-r--r-- | lib/owner.js | 6 | ||||
-rw-r--r-- | lib/ping.js | 2 | ||||
-rw-r--r-- | lib/profile.js | 2 | ||||
-rw-r--r-- | lib/publish.js | 8 | ||||
-rw-r--r-- | lib/search.js | 2 | ||||
-rw-r--r-- | lib/search/all-package-metadata.js | 2 | ||||
-rw-r--r-- | lib/star.js | 4 | ||||
-rw-r--r-- | lib/stars.js | 2 | ||||
-rw-r--r-- | lib/team.js | 2 | ||||
-rw-r--r-- | lib/token.js | 2 | ||||
-rw-r--r-- | lib/unpublish.js | 4 | ||||
-rw-r--r-- | lib/utils/metrics.js | 2 | ||||
-rw-r--r-- | lib/view.js | 9 | ||||
-rw-r--r-- | lib/whoami.js | 2 |
25 files changed, 39 insertions, 38 deletions
diff --git a/lib/access.js b/lib/access.js index e850c132e..ac8d97ce6 100644 --- a/lib/access.js +++ b/lib/access.js @@ -4,7 +4,7 @@ const BB = require('bluebird') const figgyPudding = require('figgy-pudding') -const libaccess = require('libnpm/access') +const libaccess = require('libnpmaccess') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') const otplease = require('./utils/otplease.js') diff --git a/lib/audit.js b/lib/audit.js index 7b694c13c..29101965e 100644 --- a/lib/audit.js +++ b/lib/audit.js @@ -8,7 +8,7 @@ const fs = require('graceful-fs') const Installer = require('./install.js').Installer const lockVerify = require('lock-verify') const log = require('npmlog') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const npm = require('./npm.js') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') diff --git a/lib/auth/legacy.js b/lib/auth/legacy.js index 7ad678be5..909933670 100644 --- a/lib/auth/legacy.js +++ b/lib/auth/legacy.js @@ -1,7 +1,7 @@ 'use strict' const read = require('../utils/read-user-info.js') -const profile = require('libnpm/profile') +const profile = require('npm-profile') const log = require('npmlog') const figgyPudding = require('figgy-pudding') const npmConfig = require('../config/figgy-config.js') diff --git a/lib/auth/sso.js b/lib/auth/sso.js index 099e764e3..156646ca6 100644 --- a/lib/auth/sso.js +++ b/lib/auth/sso.js @@ -9,7 +9,7 @@ const npmFetch = require('npm-registry-fetch') const output = require('../utils/output.js') const openUrl = BB.promisify(require('../utils/open-url.js')) const otplease = require('../utils/otplease.js') -const profile = require('libnpm/profile') +const profile = require('npm-profile') const SsoOpts = figgyPudding({ ssoType: 'sso-type', diff --git a/lib/deprecate.js b/lib/deprecate.js index 7fe2fbed4..e54167450 100644 --- a/lib/deprecate.js +++ b/lib/deprecate.js @@ -3,10 +3,10 @@ const BB = require('bluebird') const npmConfig = require('./config/figgy-config.js') -const fetch = require('libnpm/fetch') +const fetch = require('npm-registry-fetch') const figgyPudding = require('figgy-pudding') const otplease = require('./utils/otplease.js') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const semver = require('semver') const whoami = require('./whoami.js') diff --git a/lib/dist-tag.js b/lib/dist-tag.js index 64bb97b61..5d52a6c6e 100644 --- a/lib/dist-tag.js +++ b/lib/dist-tag.js @@ -5,12 +5,12 @@ const BB = require('bluebird') const figgyPudding = require('figgy-pudding') const log = require('npmlog') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') const otplease = require('./utils/otplease.js') const readLocalPkg = BB.promisify(require('./utils/read-local-package.js')) -const regFetch = require('libnpm/fetch') +const regFetch = require('npm-registry-fetch') const semver = require('semver') const usage = require('./utils/usage') diff --git a/lib/hook.js b/lib/hook.js index 54aea9f1e..5712ad9cd 100644 --- a/lib/hook.js +++ b/lib/hook.js @@ -2,7 +2,7 @@ const BB = require('bluebird') -const hookApi = require('libnpm/hook') +const hookApi = require('libnpmhook') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') const otplease = require('./utils/otplease.js') diff --git a/lib/install/action/extract-worker.js b/lib/install/action/extract-worker.js index 225e5b4ae..0db1144da 100644 --- a/lib/install/action/extract-worker.js +++ b/lib/install/action/extract-worker.js @@ -2,7 +2,7 @@ const BB = require('bluebird') -const extract = require('pacote/extract') +const pacote = require('pacote') // const npmlog = require('npmlog') module.exports = (args, cb) => { diff --git a/lib/logout.js b/lib/logout.js index 411f54721..1fdec88be 100644 --- a/lib/logout.js +++ b/lib/logout.js @@ -7,7 +7,7 @@ const getAuth = require('npm-registry-fetch/auth.js') const log = require('npmlog') const npm = require('./npm.js') const npmConfig = require('./config/figgy-config.js') -const npmFetch = require('libnpm/fetch') +const npmFetch = require('npm-registry-fetch') logout.usage = 'npm logout [--registry=<url>] [--scope=<@scope>]' diff --git a/lib/org.js b/lib/org.js index d8f857e3d..b1a569614 100644 --- a/lib/org.js +++ b/lib/org.js @@ -1,7 +1,7 @@ 'use strict' const figgyPudding = require('figgy-pudding') -const liborg = require('libnpm/org') +const liborg = require('libnpmorg') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') const otplease = require('./utils/otplease.js') diff --git a/lib/outdated.js b/lib/outdated.js index 5b84ae355..abce6cd29 100644 --- a/lib/outdated.js +++ b/lib/outdated.js @@ -29,14 +29,14 @@ const color = require('ansicolors') const styles = require('ansistyles') const table = require('text-table') const semver = require('semver') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const pickManifest = require('npm-pick-manifest') const fetchPackageMetadata = require('./fetch-package-metadata.js') const mutateIntoLogicalTree = require('./install/mutate-into-logical-tree.js') const npm = require('./npm.js') const npmConfig = require('./config/figgy-config.js') const figgyPudding = require('figgy-pudding') -const packument = require('libnpm/packument') +const { packument } = require('pacote') const long = npm.config.get('long') const isExtraneous = require('./install/is-extraneous.js') const computeMetadata = require('./install/deps.js').computeMetadata diff --git a/lib/owner.js b/lib/owner.js index a64cb5e14..d63f1e564 100644 --- a/lib/owner.js +++ b/lib/owner.js @@ -3,12 +3,12 @@ module.exports = owner const BB = require('bluebird') const log = require('npmlog') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const npmConfig = require('./config/figgy-config.js') -const npmFetch = require('libnpm/fetch') +const npmFetch = require('npm-registry-fetch') const output = require('./utils/output.js') const otplease = require('./utils/otplease.js') -const packument = require('libnpm/packument') +const { packument } = require('pacote') const readLocalPkg = BB.promisify(require('./utils/read-local-package.js')) const usage = require('./utils/usage') const whoami = BB.promisify(require('./whoami.js')) diff --git a/lib/ping.js b/lib/ping.js index 3023bab00..5bc503e01 100644 --- a/lib/ping.js +++ b/lib/ping.js @@ -1,7 +1,7 @@ 'use strict' const npmConfig = require('./config/figgy-config.js') -const fetch = require('libnpm/fetch') +const fetch = require('npm-registry-fetch') const figgyPudding = require('figgy-pudding') const log = require('npmlog') const npm = require('./npm.js') diff --git a/lib/profile.js b/lib/profile.js index 7ce9cb5cc..bf24f3f11 100644 --- a/lib/profile.js +++ b/lib/profile.js @@ -10,7 +10,7 @@ const npm = require('./npm.js') const npmConfig = require('./config/figgy-config.js') const otplease = require('./utils/otplease.js') const output = require('./utils/output.js') -const profile = require('libnpm/profile') +const profile = require('npm-profile') const pulseTillDone = require('./utils/pulse-till-done.js') const qrcodeTerminal = require('qrcode-terminal') const queryString = require('query-string') diff --git a/lib/publish.js b/lib/publish.js index e81fc1a05..0d3aef678 100644 --- a/lib/publish.js +++ b/lib/publish.js @@ -4,16 +4,16 @@ const BB = require('bluebird') const cacache = require('cacache') const figgyPudding = require('figgy-pudding') -const libpub = require('libnpm/publish') -const libunpub = require('libnpm/unpublish') +const libpub = require('libnpmpublish').publish +const libunpub = require('libnpmpublish').unpublish const lifecycle = BB.promisify(require('./utils/lifecycle.js')) const log = require('npmlog') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') const otplease = require('./utils/otplease.js') const pack = require('./pack') -const { tarball, extract } = require('libnpm') +const { tarball, extract } = require('pacote') const path = require('path') const readFileAsync = BB.promisify(require('graceful-fs').readFile) const readJson = BB.promisify(require('read-package-json')) diff --git a/lib/search.js b/lib/search.js index 3c59f8b43..a566d5481 100644 --- a/lib/search.js +++ b/lib/search.js @@ -6,7 +6,7 @@ const npm = require('./npm.js') const allPackageSearch = require('./search/all-package-search') const figgyPudding = require('figgy-pudding') const formatPackageStream = require('./search/format-package-stream.js') -const libSearch = require('libnpm/search') +const libSearch = require('libnpmsearch') const log = require('npmlog') const ms = require('mississippi') const npmConfig = require('./config/figgy-config.js') diff --git a/lib/search/all-package-metadata.js b/lib/search/all-package-metadata.js index 388b4f61f..5a6064401 100644 --- a/lib/search/all-package-metadata.js +++ b/lib/search/all-package-metadata.js @@ -11,7 +11,7 @@ const JSONStream = require('JSONStream') const log = require('npmlog') const mkdir = BB.promisify(require('gentle-fs').mkdir) const ms = require('mississippi') -const npmFetch = require('libnpm/fetch') +const npmFetch = require('npm-registry-fetch') const path = require('path') const sortedUnionStream = require('sorted-union-stream') const url = require('url') diff --git a/lib/star.js b/lib/star.js index 44a762b15..2356ea249 100644 --- a/lib/star.js +++ b/lib/star.js @@ -2,10 +2,10 @@ const BB = require('bluebird') -const fetch = require('libnpm/fetch') +const fetch = require('npm-registry-fetch') const figgyPudding = require('figgy-pudding') const log = require('npmlog') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const npm = require('./npm.js') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') diff --git a/lib/stars.js b/lib/stars.js index 8b28baffd..4d757385a 100644 --- a/lib/stars.js +++ b/lib/stars.js @@ -3,7 +3,7 @@ const BB = require('bluebird') const npmConfig = require('./config/figgy-config.js') -const fetch = require('libnpm/fetch') +const fetch = require('npm-registry-fetch') const log = require('npmlog') const output = require('./utils/output.js') const whoami = require('./whoami.js') diff --git a/lib/team.js b/lib/team.js index e24f73347..a9ea4a306 100644 --- a/lib/team.js +++ b/lib/team.js @@ -2,7 +2,7 @@ const columns = require('cli-columns') const figgyPudding = require('figgy-pudding') -const libteam = require('libnpm/team') +const libteam = require('libnpmteam') const npmConfig = require('./config/figgy-config.js') const output = require('./utils/output.js') const otplease = require('./utils/otplease.js') diff --git a/lib/token.js b/lib/token.js index 96a05e456..27e30a6ae 100644 --- a/lib/token.js +++ b/lib/token.js @@ -1,6 +1,6 @@ 'use strict' -const profile = require('libnpm/profile') +const profile = require('npm-profile') const npm = require('./npm.js') const figgyPudding = require('figgy-pudding') const npmConfig = require('./config/figgy-config.js') diff --git a/lib/unpublish.js b/lib/unpublish.js index 59d7d1b58..90ddfcbc4 100644 --- a/lib/unpublish.js +++ b/lib/unpublish.js @@ -6,8 +6,8 @@ module.exports = unpublish const BB = require('bluebird') const figgyPudding = require('figgy-pudding') -const libaccess = require('libnpm/access') -const libunpub = require('libnpm/unpublish') +const libaccess = require('libnpmaccess') +const libunpub = require('libnpmpublish').unpublish const log = require('npmlog') const npa = require('npm-package-arg') const npm = require('./npm.js') diff --git a/lib/utils/metrics.js b/lib/utils/metrics.js index 1a4bb79a6..c01410583 100644 --- a/lib/utils/metrics.js +++ b/lib/utils/metrics.js @@ -7,7 +7,7 @@ exports.send = sendMetrics const fs = require('fs') const path = require('path') const npm = require('../npm.js') -const regFetch = require('libnpm/fetch') +const regFetch = require('npm-registry-fetch') const uuid = require('uuid') const cacheFile = require('./cache-file.js') diff --git a/lib/view.js b/lib/view.js index a16884e25..8be277073 100644 --- a/lib/view.js +++ b/lib/view.js @@ -11,16 +11,17 @@ const columns = require('cli-columns') const npmConfig = require('./config/figgy-config.js') const log = require('npmlog') const figgyPudding = require('figgy-pudding') -const npa = require('libnpm/parse-arg') +const npa = require('npm-package-arg') const npm = require('./npm.js') -const packument = require('libnpm/packument') +const { packument } = require('pacote') const path = require('path') -const readJson = require('libnpm/read-json') +const util = require('util') +const readJson = util.promisify(require('read-package-json')) const relativeDate = require('tiny-relative-date') const semver = require('semver') const style = require('ansistyles') const usage = require('./utils/usage') -const util = require('util') + const validateName = require('validate-npm-package-name') const ViewConfig = figgyPudding({ diff --git a/lib/whoami.js b/lib/whoami.js index 5145b447d..d1a4a8f73 100644 --- a/lib/whoami.js +++ b/lib/whoami.js @@ -3,7 +3,7 @@ const BB = require('bluebird') const npmConfig = require('./config/figgy-config.js') -const fetch = require('libnpm/fetch') +const fetch = require('npm-registry-fetch') const figgyPudding = require('figgy-pudding') const npm = require('./npm.js') const output = require('./utils/output.js') |