To output colored text you need to echo the control characters for the required color, then output your text, and then (to be tidy) reset the output back to defaults. This is a companion article to How to change text color in a Linux terminal Terminal colors For instance you may want an error to appear in red, success in green, or important info to be output in bold.Īdding color to your terminal output is straightforward and involves outputting the correct control characters before your text. The default text output to a terminal is monochromatic and doesn't provide a simple method to provide context.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |