To change the color in the terminal, you must modify your .bashrc file.
You enter the terminal:
nano $HOME/.bashrc
You add to the end of the file:
export PS1="\[$(tput setaf 1)\]\u@\h:\w $ \[$(tput sgr0)\]"
Save (control + o) and then close (control + x). Now you upload your file that you just changed.
source ~/.bashrc
List of options:
- tput bold - bold
- tput rev - inverted colors
- tput sgr0 - Reset all
- tput setaf {CODE} - Set foreground color, see color {CODE}
CODE of colors:
Color {code} Color
0 Black
1 Red
2 Green
3 Yellow
4 Blue
5 Magenta
6 Cyan
7 White
Another way to change colors is using LS_COLORS:
You enter the terminal:
wget https://raw.github.com/trapd00r/LS_COLORS/master/LS_COLORS -O $HOME/.dircolors
echo 'eval $(dircolors -b $HOME/.dircolors)' >> $HOME/.bashrc
. $HOME/.bashrc
Link