diff options
author | Luke Shumaker <LukeShu@sbcglobal.net> | 2013-12-06 11:01:07 -0500 |
---|---|---|
committer | Luke Shumaker <LukeShu@sbcglobal.net> | 2013-12-06 11:01:07 -0500 |
commit | 1d72c16c1f1b3d540ba51636dde5cc3caf8a9bb6 (patch) | |
tree | 50f7c531520b58e3397206b83f99de5c0fa6e6a6 | |
parent | 8daf85a3e13a10f8e25f3c60713162057122e6e7 (diff) |
bash/rc.sh: fix PS1 on non-colored terminals
-rw-r--r-- | .config/bash/rc.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/.config/bash/rc.sh b/.config/bash/rc.sh index 447796a..633f81e 100644 --- a/.config/bash/rc.sh +++ b/.config/bash/rc.sh @@ -57,7 +57,7 @@ if tput setaf 1 &>/dev/null; then _STATUS+="\$(v=\$?; [[ \$v = 0 ]] && c='${GREEN}' || c='${RED}'; printf %s%03i \$c \$v)" _STATUS+="${RESET}${BOLD}]${RESET}" else - _STATUS='[$?]' + _STATUS='[$(printf "%03i" $?)]' fi PS1="${_STATUS} $(make_prompt)"'\n\$ ' unset RESET BOLD RED GREEN BLUE _STATUS |