Do not wrap lines if we can't read term size

This commit is contained in:
Maciej Szulik 2022-04-29 14:01:14 +02:00
parent 537941765f
commit a1c90674b5
No known key found for this signature in database
GPG Key ID: F15E55D276FA84C4

View File

@ -223,7 +223,7 @@ func flagsUsages(f *flag.FlagSet) (string, error) {
flagBuf := new(bytes.Buffer)
wrapLimit, err := term.GetWordWrapperLimit()
if err != nil {
return "", err
wrapLimit = 0
}
printer := NewHelpFlagPrinter(flagBuf, wrapLimit)