Change --useColors to --colors:on|off and add help

Since we introduced automatic colors on terminals (via isatty) there is no way
to turn it off, since (undocumented) --useColors just turns them on.

This replaces --useColors with --colors:on|off, so anyone who prefers
non-colored compiler messages may now turn it off now.
This commit is contained in:
Adam Strzelecki 2015-06-24 19:50:51 +02:00
commit 67fac7f1e7
2 changed files with 2 additions and 3 deletions

View file

@ -537,9 +537,7 @@ proc processSwitch(switch, arg: string, pass: TCmdLinePass, info: TLineInfo) =
of "genscript":
expectNoArg(switch, arg, pass, info)
incl(gGlobalOptions, optGenScript)
of "usecolors":
expectNoArg(switch, arg, pass, info)
incl(gGlobalOptions, optUseColors)
of "colors": processOnOffSwitchG({optUseColors}, arg, pass, info)
of "lib":
expectArg(switch, arg, pass, info)
libpath = processPath(arg, notRelativeToProj=true)