Cshell help with change colour in print

i want to ask how to change the colour of prompt message from use?
and also how to change colour in printing........

i want to change it as blue colour and red colour, but i found many website still don't know how to do. how's the command is wrote?

thz really!!

This might only work for tcsh, but I have this in my /etc/csh.cshrc:

set prompt = "%{\033[0;1;34m%}(%{\033[0;1;31m%}%m%{\033[0m%}:%{\033[0;1;34m%}%c3%{\033[0;1;34m%}) %{\033[0;1;31m%}%#%{\033[0m%} "

...which sets a color prompt. This is how it works:

"%{\033[0;1;34m%}

The %{...%} stuff seems necessary to print raw escape characters, otherwise it prints ^[ instead of ESC. So this ends up printing the escape sequence for high-intensity blue.

This works only in the prompt variable though. To get a raw ESC somewhere else you have to printf it, you can't echo it.

printf "\033[0;1;34m%The following text should be blue\033[0m"

The first bit sets it blue, the second bit resets it to defaults. See ASCII Table - ANSI Escape sequences for possible numbers for the 'set graphics mode' command, you can string them in a line like "0;1;34" for "reset defaults", "high intensity", "blue". Add the head and tail and you get \033[0;1;34m