neofs-node
neofs-node copied to clipboard
cli: Do not print help on any failure
Any error returned by implemented command executor leads to additional help output. It is useful when the user incorrectly formed a command, but not more.
Solution
Replace providing the RunE
calls of to cobra.Command
(errors of which are actually lead to help
) with Run
. With this approach command misprints are still handled, but other errors are written user friendly.
For errors cmd.PrintErr
function group, for logs - cmd.Print*
w/o Err
.