I have always been using below method to highlight background of text in shell .
tput smso;printf " TEXT ";tput rmso;
How can I achieve the same thing without using
tput( I mean some way formatting like
\e[0m for colors in printf) ?
The escape sequences for that may be terminal specific. That's the whole point of using
On my terminal:
So I could do:
But I can't be sure that would work on other terminals.
If you don't want to call