added condition check to prevent sourcing the prompt if no $TERM as tput needs it
This commit is contained in:
parent
178ac74822
commit
17f3bd32ba
@ -35,7 +35,7 @@
|
|||||||
# green = no changes or commits
|
# green = no changes or commits
|
||||||
|
|
||||||
# Check for recent enough version of bash.
|
# Check for recent enough version of bash.
|
||||||
[ -z "$BASH_VERSION" -o -z "$PS1" ] && return;
|
[ -z "$BASH_VERSION" -o -z "$PS1" -o -z "$TERM" ] && return;
|
||||||
|
|
||||||
bash=${BASH_VERSION%.*}; bmajor=${bash%.*}; bminor=${bash#*.}
|
bash=${BASH_VERSION%.*}; bmajor=${bash%.*}; bminor=${bash#*.}
|
||||||
if [ $bmajor -lt 3 ] || [ $bmajor -eq 3 -a $bminor -lt 2 ]; then
|
if [ $bmajor -lt 3 ] || [ $bmajor -eq 3 -a $bminor -lt 2 ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user