.gitignore | ||
bash-color-prompt.sh | ||
COPYING | ||
README.md | ||
shell-color-prompt.spec | ||
sources |
Simple colored bash prompt
The prompt color theme can be customized simply by setting
the PROMPT_COLOR
envvar.
For example PROMPT_COLOR='2;7'
is dim inverse-video
and PROMPT_COLOR='1;33;53'
is bright/bold yellow with overline.
Set prompt_color_force
(before source'ing) to force usage/updating of color PS1:
by default it is only setup cautiously if $TERM
ends in "color"
and PS1 is the fedora default.
Also set PROMPT_ERROR
if you want to append red error exit codes to the prompt.
See /etc/profile.d/bash-color-prompt.sh
for the actual script.
Please report bugs against shell-color-prompt.
References
See https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_(Select_Graphic_Rendition)_parameters etc for the ANSI codes.