Commit 68e28998 authored by Jordi Martin's avatar Jordi Martin Committed by Bryan C. Mills

cmd/go: keep "go help" in unknown topic suggestion

Fixed missing concatenation to build the suggested command.

Fixes #33153

Change-Id: I26c02f2966247aa07d1447b8ec1a2203046842dd
GitHub-Last-Rev: 9631abf1d0d187cbd94495a2a789e5863b421441
GitHub-Pull-Request: golang/go#33245
Reviewed-on: https://go-review.googlesource.com/c/go/+/187217Reviewed-by: default avatarBryan C. Mills <bcmills@google.com>
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
parent e8c7e639
......@@ -63,7 +63,7 @@ Args:
// helpSuccess is the help command using as many args as possible that would succeed.
helpSuccess := "go help"
if i > 0 {
helpSuccess = " " + strings.Join(args[:i], " ")
helpSuccess += " " + strings.Join(args[:i], " ")
}
fmt.Fprintf(os.Stderr, "go help %s: unknown help topic. Run '%s'.\n", strings.Join(args, " "), helpSuccess)
base.SetExitStatus(2) // failed at 'go help cmd'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment