Is there a way to color particular words printed on console based on user preference?
For example I need to color text 'error' when a particular program is compiled.
You'll need to work with the output and some script/alias. Check So You Like Colors for reference of how to use colors in terminal.
BEWARE: the first
Result in that: You should setup some script/alias in your ~/.bashrc.