this is more a question about fashion than functionality. I really like the way the bash is colored by default in Raspbian, I find it very helpful and pleasant to the eyes. That being said, I also run a Debian machine and I would really like to have its bash to be colorized just like the Raspbian one. How can I do that? Thanks in advance.

  • 1
    ExploWare did a good job of explaining ls. For more about the command prompt see here and here. The prompt colors are done with ANSI escape sequences compatible with any terminal on linux (e.g., try echo -e "\033[32mcheese\033[0m" and don't forget the -e). There's a generic guide to those in wikipedia.
    – goldilocks
    Mar 5, 2014 at 14:31
  • Whoops! Those two "here"s are the same link. This is the other one: unix.stackexchange.com/questions/148/…
    – goldilocks
    Mar 5, 2014 at 14:46

1 Answer 1


Take a look at the lines starting with PS1 in /etc/bash.bashrc and/or /home/pi/.bashrc Those lines set the (color)layout for the prompt, the line where you can type at.

for the colors in a filelisting by executing ls the option --color=auto is useful. this may also be defined as an alias; try executing this:

alias ls='ls --color=auto'
ls ~  
ls -la ~  

Do you like these colors to be permanent on your Debian (or any other color-enabled terminal, like shipped with Ubuntu, Suse, Arch, etc.) then copy the PS1 lines and the alias line to the ~/.bashrc or /etc/bash.bashrc at a linuxcomputer of your choice :)

BTW: googling for "PS1 bash" will show you even more ways to make a pretty prompt, like adding a timestamp

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.