From: Matthijs Kooijman Date: Wed, 29 Feb 2012 12:05:00 +0000 (+0100) Subject: bash: Enable colored prompts by default X-Git-Url: https://git.stderr.nl/gitweb?p=matthijs%2Fservers%2Ftika.git;a=commitdiff_plain;h=fe69437282ce24f492429589b24f651f0df62c01 bash: Enable colored prompts by default --- diff --git a/etc/bash.bashrc b/etc/bash.bashrc index aa84d91..169413a 100644 --- a/etc/bash.bashrc +++ b/etc/bash.bashrc @@ -28,6 +28,12 @@ PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' # ;; #esac +# Enable colored prompts by default (note that unlike what the name suggests, +# this actually doesn't force anything, but triggers a color-detection snippet +# in ~/.bashrc). Users can override this value (or just throw out the snippet +# or customize the prompt) in their ~/.bashrc as well. +force_color_prompt=yes + # enable bash completion in interactive shells if [ -f /etc/bash_completion ] && ! shopt -oq posix; then . /etc/bash_completion diff --git a/etc/skel/.bashrc b/etc/skel/.bashrc index e96b37f..17c7b51 100644 --- a/etc/skel/.bashrc +++ b/etc/skel/.bashrc @@ -33,10 +33,9 @@ case "$TERM" in xterm-color) color_prompt=yes;; esac -# uncomment for a colored prompt, if the terminal has the capability; turned -# off by default to not distract the user: the focus in a terminal window -# should be on the output of commands, not on the prompt -#force_color_prompt=yes +# colored prompts are enabled by default in /etc/bash.bashrc, uncomment this to +# disable them. +#force_color_prompt= if [ -n "$force_color_prompt" ]; then if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then