go-supportscolor
go-supportscolor copied to clipboard
Does not recognize "-no-color"
(Got here from gchalk - thanks for that!)
It looks like this only looks for "double-dash" options? i.e. --no-color
I would have expected it to support -no-color
as well. Took me a while to figure out why it wasn't working.
(It would also be nice to have it support the proper spelling of colour
throughout as well 😄 - waves from downtown YOW!)
Chalk only supports --no-color
, so I followed suit with gchalk. And, generally a single dash would be for a bunch of single options. For example, -no
would be the same as -n -o
(although I admit that's a Unix convention).
I'm happy to add --no-colour
. I'm in YOW as well. :)
And, generally a single dash would be for a bunch of single options.
Yes - for some cases & it's really just convention. (I'm very old-school, so --foo
still feels strange 😆 ). Would be good to be more flexible IMHO.
I'm using gchalk in combination with urfave/cli which accepts both -no-color
and --no-color
as the same thing, but only --no-color
actually works. So either I ignore it, or I need add some extra fiddling to check for the "one-dash" case and then call gchalk.SetLevel( gchalk.LevelNone )
.
I'm in YOW as well
I saw that - Winter has come!
Thanks Jason - have a great week.