I have a C program that outputs a color code that bash understands perfectly well but other terminals may not. The idea, then, would be to have my program color the string according to the rules of the terminal running the program. If it is running in "bash", it will output the string I have so far; if not, and there are no other supported terminals, the program will output a plain string.