Currently all info logged by tfcmd (I believe tfrobot too) gets styled with colors and bold text using terminal escape sequences. This is not ideal when capturing and parsing this output.
Even the json returned from get commands is wrapped in escape sequences:
$ tfcmd get vm myctest &> output
$ cat -v output
...
"ContractID": 668773,
"IPrange": "10.20.2.0/24"
}^[[0m
I'd suspect that the logging library we use has an option to disable the styles. If we can just expose that to the user as a cli flag, that would be a quick fix to improve the situation.
Currently all info logged by tfcmd (I believe tfrobot too) gets styled with colors and bold text using terminal escape sequences. This is not ideal when capturing and parsing this output.
Even the json returned from
get
commands is wrapped in escape sequences:I'd suspect that the logging library we use has an option to disable the styles. If we can just expose that to the user as a cli flag, that would be a quick fix to improve the situation.