diff options
author | isaacs <i@izs.me> | 2011-10-25 23:04:08 +0400 |
---|---|---|
committer | isaacs <i@izs.me> | 2011-10-25 23:10:45 +0400 |
commit | d526a6703e886898effb017239cfaf597b9024cf (patch) | |
tree | 23a6f03d79667b8ac9070dace4e0c7995c129145 /lib | |
parent | b7d33afc59258d0acb749f332ba7b4601c786537 (diff) |
fix link regression, regarding new path getters
Diffstat (limited to 'lib')
-rw-r--r-- | lib/build.js | 4 | ||||
-rw-r--r-- | lib/link.js | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/build.js b/lib/build.js index 526a831cb..864eb27cf 100644 --- a/lib/build.js +++ b/lib/build.js @@ -72,7 +72,7 @@ function linkStuff (pkg, folder, global, didRB, cb) { // then bins are in {prefix}/bin // otherwise, then bins are in folder/../.bin var parent = path.dirname(folder) - , gnm = global && npm.dir + , gnm = global && npm.globalDir , top = parent === npm.dir , gtop = parent === gnm @@ -131,7 +131,7 @@ function linkBins (pkg, folder, parent, gtop, cb) { if (!pkg.bin || !gtop && path.basename(parent) !== "node_modules") { return cb() } - var binRoot = gtop ? npm.bin + var binRoot = gtop ? npm.globalBin : path.resolve(parent, ".bin") log.verbose([pkg.bin, binRoot, gtop], "bins linking") diff --git a/lib/link.js b/lib/link.js index 26ac112ac..fea660666 100644 --- a/lib/link.js +++ b/lib/link.js @@ -58,8 +58,8 @@ function linkInstall (pkgs, cb) { next() } - var t = npm.globalDir - , pp = path.resolve(npm.dir, pkg) + var t = path.resolve(npm.globalDir, "..") + , pp = path.resolve(npm.globalDir, pkg) , rp = null , target = path.resolve(npm.dir, pkg) |