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/npm.js
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2011-01-12 05:05:29 +0300
committerisaacs <i@izs.me>2011-01-12 05:05:29 +0300
commit27b9f7b4d79a76e1d490cd4e5fef3a187d5f62a1 (patch)
tree3956c9d981f4924cdc0c5e24dabdefff384e8509 /npm.js
parent916e1baa7d05253fbe305b4a04962fa67d486033 (diff)
Fix #499. Only mkdir when appropriate.
This is a pretty significant clean-up of many relics. Once upon a time, npm was only one or two commands, and when you needed a directory made, by golly, you made it yourself. If you needed to write a file, you wrote it yourself. Uphill in the snow. Yeah. Then, modernity arrived, and things got abstracted. Now, instead of writing your own file, the kids today with their rock and roll music and their hair and their marijuana cigarettes, you know what they do? They call some external utility to write it FOR them! That means that there's no need to make any directories at config loading time. Since many commands don't need it, this is a nuisance. Also, it's more clutter, and interferes with the planned permissions handling schemes.
Diffstat (limited to 'npm.js')
-rw-r--r--npm.js6
1 files changed, 1 insertions, 5 deletions
diff --git a/npm.js b/npm.js
index fef43b570..3008f2884 100644
--- a/npm.js
+++ b/npm.js
@@ -18,7 +18,6 @@ var EventEmitter = require("events").EventEmitter
, log = require("./lib/utils/log")
, fs = require("./lib/utils/graceful-fs")
, path = require("path")
- , mkdir = require("./lib/utils/mkdir-p")
, abbrev = require("./lib/utils/abbrev")
, which = require("./lib/utils/which")
@@ -138,10 +137,7 @@ npm.load = function (conf, cb_) {
log.verbose("node symlink", node)
process.execPath = node
}
- ini.resolveConfigs(conf, function (er) {
- if (er) return cb(er)
- mkdir(npm.tmp, cb)
- })
+ ini.resolveConfigs(conf, cb)
})
}