I have a list of sentences in a tcsh script, which are separated by '\n' and may have white spaces inside. I want to show them in the style of ls, so I did "echo $list| column". it works fine when there is no color used. the result is as below
Then I need to highlight some items which are changed(latest 3 choices) each time to show up. I add the color sequences (\e[33m and \e[0m) around the items I want to highlight, and still put them into the $list.
When I show them with "echo $list | column", the color is ok, but the text are misaligned as following picture.
Note, I tried that if not use '| column', the strings showed correctly in one column, even though not the style I want.
Is there is some solution for the problem?
BTW, I did some search and it seems to be a bug of column. Is there any maintainer for column? Where should I report the issue?
NOTE: I've read Issue with column command and color escape codes before the post. His format is fixed, while mine to be colored items are dynamic. So simply use printf or add color after column can not work
column
. I've added an answer demonstrating this