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
diff options
context:
space:
mode:
Diffstat (limited to 'lib/link.js')
-rw-r--r--lib/link.js11
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/link.js b/lib/link.js
index 3049884ca..c7bf6eafe 100644
--- a/lib/link.js
+++ b/lib/link.js
@@ -5,7 +5,7 @@
var npm = require("./npm.js")
, symlink = require("./utils/link.js")
, fs = require("graceful-fs")
- , log = require("./utils/log.js")
+ , log = require("npmlog")
, asyncMap = require("slide").asyncMap
, chain = require("slide").chain
, path = require("path")
@@ -85,7 +85,7 @@ function linkInstall (pkgs, cb) {
next()
} else {
return fs.realpath(pp, function (er, real) {
- if (er) log.warn(pkg, "invalid symbolic link")
+ if (er) log.warn("invalid symbolic link", pkg)
else rp = real
next()
})
@@ -95,7 +95,10 @@ function linkInstall (pkgs, cb) {
function next () {
chain
( [ [npm.commands, "unbuild", [target]]
- , [log.verbose, "symlinking " + pp + " to "+target, "link"]
+ , [function (cb) {
+ log.verbose("link", "symlinking %s to %s", pp, target)
+ cb()
+ }]
, [symlink, pp, target]
// do run lifecycle scripts - full build here.
, rp && [build, [target]]
@@ -120,7 +123,7 @@ function linkPkg (folder, cb_) {
if (er) return cb(er)
symlink(me, target, function (er) {
if (er) return cb(er)
- log.verbose(target, "link: build target")
+ log.verbose("link", "build target", target)
// also install missing dependencies.
npm.commands.install(me, [], function (er, installed) {
if (er) return cb(er)