cargo-asm icon indicating copy to clipboard operation
cargo-asm copied to clipboard

cargo-asm prints color codes even when stdout is not a terminal

Open bheisler opened this issue 4 years ago • 1 comments

When I try to run cargo asm <args> | less I see a bunch of escape codes in less. It would be nice if cargo-asm could detect if stdout is a terminal, or at least provide a --color=never option.

bheisler avatar Jul 16 '20 23:07 bheisler

I don't think this is a bug as you might want color codes when stdout is not terminal, e.g. to save to file which you then open in editor which supports color codes.

Also there is already --no-color to not output colors.

malaire avatar Jun 02 '21 12:06 malaire