Colours sould only be enabled when the terminal supports them.
For example, when redirecting output or piping to cat, there should be no escape sequences.
I believe there needs to be a condition around the pretty method (or maybe it should be handled by tracing_subscriber::fmt):
Examples:
stackablectl --log-level=DEBUG stack list > /tmp/stackablectl.stdout # plain redirect
stackablectl --log-level=DEBUG stack list | cat > /tmp/stackablectl.stdout # pipe through cat
TERM= stackablectl --log-level=DEBUG stack list > /tmp/stackablectl.stdout # explicitly set TERM to nothing
If I open it in VIM, it looks like this:

Colours sould only be enabled when the terminal supports them.
For example, when redirecting output or piping to
cat, there should be no escape sequences.I believe there needs to be a condition around the
prettymethod (or maybe it should be handled bytracing_subscriber::fmt):stackable-cockpit/rust/stackablectl/src/main.rs
Line 31 in fe37d49
Examples:
If I open it in VIM, it looks like this: