]> git.donarmstrong.com Git - home-base.git/blobdiff - .bashrc
* Handle older versions of toe
[home-base.git] / .bashrc
diff --git a/.bashrc b/.bashrc
index 99e079c86000d2a7236cc1cd7be2822d862ee87b..189377b4025a45c57a279a772cd022cae57aadad 100644 (file)
--- a/.bashrc
+++ b/.bashrc
@@ -36,7 +36,11 @@ if [ "$PS1" ]; then
     # \[\033[1;36m\][\w]\n\[\033[0;36m\][\h|\t]$ \[\033[0m\]
 
     # make sure the term we're using exists in the termcap
     # \[\033[1;36m\][\w]\n\[\033[0;36m\][\h|\t]$ \[\033[0m\]
 
     # make sure the term we're using exists in the termcap
-    if ! toe -a|grep -q "^$TERM        "; then
+    TOEOPT='-a'
+    if ! toe $TOEOPT >/dev/null 2>&1; then
+       TOEOPT=''
+    fi;
+    if ! toe $TOEOPT|grep -q "^$TERM   "; then
        # if it doesn't, try to switch
        case $TERM in
            rxvt*)
        # if it doesn't, try to switch
        case $TERM in
            rxvt*)