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
path: root/lib/ci.js
diff options
context:
space:
mode:
authorKat Marchán <kzm@zkat.tech>2018-09-01 02:25:44 +0300
committerKat Marchán <kzm@zkat.tech>2018-12-11 02:30:29 +0300
commit41d19e18f769c6f0acfdffbdb01d12bf332908ce (patch)
tree8b48c1f732c30c53d9d44e0271606d3c45d6f887 /lib/ci.js
parent8a56fa39e61136da45565447fe201a57f04ad4cd (diff)
pacote: get rid of legacy pacoteOpts
Diffstat (limited to 'lib/ci.js')
-rw-r--r--lib/ci.js35
1 files changed, 7 insertions, 28 deletions
diff --git a/lib/ci.js b/lib/ci.js
index 03822b952..1fbb28b57 100644
--- a/lib/ci.js
+++ b/lib/ci.js
@@ -1,40 +1,19 @@
'use strict'
const Installer = require('libcipm')
-const lifecycleOpts = require('./config/lifecycle.js')
-const npm = require('./npm.js')
+const npmConfig = require('./config/figgy-config.js')
const npmlog = require('npmlog')
-const pacoteOpts = require('./config/pacote.js')
ci.usage = 'npm ci'
ci.completion = (cb) => cb(null, [])
-Installer.CipmConfig.impl(npm.config, {
- get: npm.config.get,
- set: npm.config.set,
- toLifecycle (moreOpts) {
- return lifecycleOpts(moreOpts)
- },
- toPacote (moreOpts) {
- return pacoteOpts(moreOpts)
- }
-})
-
module.exports = ci
function ci (args, cb) {
- return new Installer({
- config: npm.config,
- log: npmlog
- })
- .run()
- .then(
- (details) => {
- npmlog.disableProgress()
- console.log(`added ${details.pkgCount} packages in ${
- details.runTime / 1000
- }s`)
- }
- )
- .then(() => cb(), cb)
+ return new Installer(npmConfig({ log: npmlog })).run().then(details => {
+ npmlog.disableProgress()
+ console.log(`added ${details.pkgCount} packages in ${
+ details.runTime / 1000
+ }s`)
+ }).then(() => cb(), cb)
}