Skip to content
Browse files

Remove symbolic links from npm itself

  • Loading branch information...
1 parent c6872b3 commit 48f132218ccda9a78621ca31eaf0ec430f99b67f @isaacs isaacs committed Nov 29, 2011
Showing with 5 additions and 19 deletions.
  1. +0 −1 CHANGES
  2. +0 −1 doc/api/author.md
  3. +0 −1 doc/api/find.md
  4. +0 −1 doc/api/get.md
  5. +0 −1 doc/api/home.md
  6. +0 −1 doc/api/list.md
  7. +0 −1 doc/api/ln.md
  8. +0 −1 doc/api/rm.md
  9. +0 −1 doc/api/set.md
  10. +0 −1 doc/cli/author.md
  11. +0 −1 doc/cli/find.md
  12. +0 −1 doc/cli/get.md
  13. +0 −1 doc/cli/global.md
  14. +0 −1 doc/cli/home.md
  15. +0 −1 doc/cli/ln.md
  16. +0 −1 doc/cli/ls.md
  17. +0 −1 doc/cli/rm.md
  18. +0 −1 doc/cli/set.md
  19. +5 −1 lib/help.js
View
1 CHANGES
View
1 doc/api/author.md
View
1 doc/api/find.md
View
1 doc/api/get.md
View
1 doc/api/home.md
View
1 doc/api/list.md
View
1 doc/api/ln.md
View
1 doc/api/rm.md
View
1 doc/api/set.md
View
1 doc/cli/author.md
View
1 doc/cli/find.md
View
1 doc/cli/get.md
View
1 doc/cli/global.md
View
1 doc/cli/home.md
View
1 doc/cli/ln.md
View
1 doc/cli/ls.md
View
1 doc/cli/rm.md
View
1 doc/cli/set.md
View
6 lib/help.js
@@ -26,7 +26,7 @@ function help (args, cb) {
return npm.commands["help-search"](args, num, cb)
}
- var section = args[0]
+ var section = npm.deref(args[0]) || args[0]
if (section) {
if ( npm.config.get("usage")
@@ -36,6 +36,7 @@ function help (args, cb) {
npm.config.set("loglevel", "silent")
return output.write(npm.commands[section].usage, cb)
}
+
var sectionPath = path.join( __dirname, "..", "man", "man" + num
, section + "." + num)
, htmlPath = path.resolve( __dirname, "..", "html"
@@ -53,11 +54,13 @@ function help (args, cb) {
})
env.MANPATH = manpath
var viewer = npm.config.get("viewer")
+
switch (viewer) {
case "woman":
var a = ["-e", "(woman-find-file \"" + sectionPath + "\")"]
exec("emacsclient", a, env, true, cb)
break
+
case "browser":
var b = npm.config.get("browser")
if (!b) {
@@ -71,6 +74,7 @@ function help (args, cb) {
exec(b, [htmlPath], env, false, function () {})
}
break
+
default:
exec("man", [num, section], env, true, cb)
}

0 comments on commit 48f1322

Please sign in to comment.
Something went wrong with that request. Please try again.