Lines Matching +full:pkg +full:- +full:config
3 const deepSortObject = require('../utils/deep-sort-object.js')
4 const detectIndent = require('detect-indent')
5 const detectNewline = require('detect-newline')
6 const fs = require('graceful-fs')
9 const moduleName = require('../utils/module-name.js')
11 const packageId = require('../utils/package-id.js')
12 const parseJSON = require('../utils/parse-json.js')
14 const stringifyPackage = require('stringify-package')
17 const writeFileAtomic = require('write-file-atomic')
19 // if the -S|--save option is specified, then write installed packages
48 …if (!npm.config.get('package-lock-only') && (!npm.config.get('shrinkwrap') || !npm.config.get('pac…
56 var saveBundle = npm.config.get('save-bundle')
58 // each item in the tree is a top-level thing that should be saved
60 // The relevant tree shape is { <folder>: {what:<pkg>} }
63 // tricky npm-specific stuff that's in there.
83 toSave.forEach(function (pkg) { if (pkg.save) savingTo[pkg.save] = true }) argument
84 toRemove.forEach(function (pkg) { if (pkg.save) savingTo[pkg.save] = true }) argument
92 toSave.forEach(function (pkg) { argument
93 if (pkg.save) tree.package[pkg.save][pkg.name] = pkg.spec
97 pkg.save !== saveType &&
99 tree.package[saveType][pkg.name]
102 delete tree.package[saveType][pkg.name]
106 … log.notice('save', `${pkg.name} is being moved from ${movedFrom.join(' and ')} to ${pkg.save}`)
109 var ii = bundle.indexOf(pkg.name)
110 if (ii === -1) bundle.push(pkg.name)
114 toRemove.forEach(function (pkg) { argument
115 if (pkg.save) delete tree.package[pkg.save][pkg.name]
117 bundle = without(bundle, pkg.name)
143 var globalInstall = npm.config.get('global')
144 var noSaveFlags = !npm.config.get('save') &&
145 !npm.config.get('save-dev') &&
146 !npm.config.get('save-prod') &&
147 !npm.config.get('save-optional')
150 if (npm.config.get('save-optional')) {
152 } else if (npm.config.get('save-dev')) {
154 } else if (npm.config.get('save-prod')) {