Saturday, May 7, 2022

[SOLVED] What does "[0;31m" means?

Issue

I saw this string in many places,but what does it means ?

For example : https://github.com/ibnYusrat/my-linux-setup/blob/master/setup.sh

example in github


Solution

This is a ANSI escape sequence. It's mainly used to colorize/format your shell's standard out. Please find a list of valid sequences here.
Regarding the title of this thread --> \033[0;31m start's to colorize your output red. Please be aware that you must reset your sequence with \033[0m.
See attached an example: enter image description here



Answered By - Krischa Onarestlessday
Answer Checked By - Senaida (WPSolving Volunteer)