Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
When installing npm, keep the builtin config
  • Loading branch information
isaacs committed Oct 8, 2011
1 parent a5bbf48 commit a7da307
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/build.js
Expand Up @@ -50,6 +50,7 @@ function build_ (global, didPre, didRB) { return function (folder, cb) {
chain
( [ !didPre && [lifecycle, pkg, "preinstall", folder]
, [linkStuff, pkg, folder, global, didRB]
, pkg.name === "npm" && [writeBuiltinConf, folder]
, didPre !== build._noLC && [lifecycle, pkg, "install", folder]
, didPre !== build._noLC && [lifecycle, pkg, "postinstall", folder]
, didPre !== build._noLC
Expand All @@ -59,6 +60,11 @@ function build_ (global, didPre, didRB) { return function (folder, cb) {
})
}}

function writeBuiltinConf (folder, cb) {
var ini = require("./utils/ini.js")
ini.saveConfig("builtin", cb)
}

function linkStuff (pkg, folder, global, didRB, cb) {
// if it's global, and folder is in {prefix}/node_modules,
// then bins are in {prefix}/bin
Expand Down

0 comments on commit a7da307

Please sign in to comment.