cpisciotta / xcbeautify

A little beautifier tool for xcodebuild
MIT License
915 stars 62 forks source link

Cannot set environment variable NO_COLOR #283

Open ikelax opened 4 weeks ago

ikelax commented 4 weeks ago

If I set the environment variable NO_COLOR, e.g. to true, and run swift test | ./xcbeautify, I get this error message

ArgumentParser/ParsableArguments.swift:283: Fatal error: Validation failed for `Xcbeautify`:

- One or more Boolean flags is declared with an initial value of `true`.
This results in the flag always being `true`, no matter whether the user
specifies the flag or not.

To resolve this error, change the default to `false`, provide a value
for the `inversion:` parameter, or remove the `@Flag` property wrapper
altogether.

Affected flag(s):
--disable-colored-output

Building for debugging...
[2/2] Write swift-version--58304C5D6DBC2206.txt
Build complete! (2.80s)
fish: Process 40787, './xcbeautify' from job 1, 'swift test | ./xcbeautify' terminated by signal SIGTRAP (Trace or breakpoint trap)

Running the command in zsh, yields a similar output

ArgumentParser/ParsableArguments.swift:283: Fatal error: Validation failed for `Xcbeautify`:

- One or more Boolean flags is declared with an initial value of `true`.
This results in the flag always being `true`, no matter whether the user
specifies the flag or not.

To resolve this error, change the default to `false`, provide a value
for the `inversion:` parameter, or remove the `@Flag` property wrapper
altogether.

Affected flag(s):
--disable-colored-output

Building for debugging...
[2/2] Write swift-version--58304C5D6DBC2206.txt
Build complete! (2.08s)
zsh: broken pipe  swift test | 
zsh: trace trap   ./xcbeautify