You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Default output for "unknown command" is getting printed two times.
For example:
The command is given command is "pri1" and the actual one is "print"
subcommand pri1 return
Error: unknown command "pri1" for "hoster"
Did you mean this?
print
Run 'hoster --help' for usage.
unknown command "pri1" for "hoster"
Did you mean this?
print
The text was updated successfully, but these errors were encountered:
This happens because the error is output both when it happens https://github.com/spf13/cobra/blob/master/command.go#L841-L842 and probably in your cmd/root.go also. Removing fmt.Println(err) from my Execute() function in the root command has stopped this showing twice but if any other error is returned, it won't be output so this might not be the best solution!
Default output for "unknown command" is getting printed two times.
For example:
The command is given command is "pri1" and the actual one is "print"
The text was updated successfully, but these errors were encountered: