sg: better output when using 'sg live' wrong
Created by: mrnugget
Before this change sg live
would print the helptext for sg
on error. That output is not only super long and hides the error, but it also doesn't tell you anything about sg live
.
So I changed the error handler to print the helptext for subcommands, which is what we want in 99% of cases, I think, since sg
itself is not a useful command, only its subcommands.
I also changed the error output of sg live
to be a bit more consistent and more helpful.
Before
After
Test plan
- Tested locally with
go run . live cloud
andgo run . live dotcom