Skip to content
Permalink
Browse files
usage: Correct "npm COMMAND help" to "npm help COMMAND"
PR-URL: #2855
Credit: @dwardu
Close: #2855
Reviewed-by: @ruyadorno, @darcyclarke
  • Loading branch information
dwardu authored and ruyadorno committed Mar 11, 2021
1 parent b0ae548 commit 8c44e999bdf7639893535c55beebf7996da2c47f
@@ -19,7 +19,7 @@ class BaseCommand {

// Mostly this just appends aliases, this could be more clear
usage = usageUtil(this.constructor.name, usage)
usage = `${usage}\n\nRun "npm ${this.constructor.name} help" for more info`
usage = `${usage}\n\nRun "npm help ${this.constructor.name}" for more info`
return usage
}

@@ -15,7 +15,7 @@ npm dist-tag ls [<pkg>]
alias: dist-tags
Run "npm dist-tag help" for more info
Run "npm help dist-tag" for more info
`

exports[`test/lib/dist-tag.js TAP add missing pkg name > should exit usage error message 1`] = `
@@ -28,7 +28,7 @@ npm dist-tag ls [<pkg>]
alias: dist-tags
Run "npm dist-tag help" for more info
Run "npm help dist-tag" for more info
`

exports[`test/lib/dist-tag.js TAP add new tag > should return success msg 1`] = `
@@ -50,7 +50,7 @@ npm dist-tag ls [<pkg>]
alias: dist-tags
Run "npm dist-tag help" for more info
Run "npm help dist-tag" for more info
`

exports[`test/lib/dist-tag.js TAP ls in current package > should list available tags for current package 1`] = `
@@ -69,7 +69,7 @@ npm dist-tag ls [<pkg>]
alias: dist-tags
Run "npm dist-tag help" for more info
Run "npm help dist-tag" for more info
`

exports[`test/lib/dist-tag.js TAP ls on missing package > should log no dist-tag found msg 1`] = `
@@ -118,7 +118,7 @@ npm dist-tag ls [<pkg>]
alias: dist-tags
Run "npm dist-tag help" for more info
Run "npm help dist-tag" for more info
`

exports[`test/lib/dist-tag.js TAP remove non-existing tag > should log error msg 1`] = `
@@ -11,5 +11,5 @@ npm publish
Usage:
npm publish [<folder>] [--tag <tag>] [--access <public|restricted>] [--dry-run]
Run "npm publish help" for more info
Run "npm help publish" for more info
`

0 comments on commit 8c44e99

Please sign in to comment.