Skip to content

Commit 2c0ba25

Browse files
committed
Add cautionary tale
1 parent 82b2c7e commit 2c0ba25

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

cmd/src/cmd.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@ type commander []*command
4545
// Run the command
4646
func (c commander) run(flagSet *flag.FlagSet, cmdName, usageText string, args []string) {
4747

48+
// NOTE: This function is quite brittle
49+
// Especially with printing helper text at all 3 different levels of depth
50+
4851
// Check if --help args are anywhere in the command
4952
// If yes, then remove it from the list of args at this point,
5053
// then append it to the deepest command / subcommand, later,

0 commit comments

Comments
 (0)