> Well ok its not just a plain colored prompt, what I would like to use is
> this:
> 
>     txtred='\e[0;31m' # Red
>     bldgrn='\e[1;32m' # Green
>     txtrst='\e[0m'    # Text Reset
>     PROMPT_COMMAND=' \
>         if [ $? -eq 0 ]; then \
>             PROMPT_PREFIX="$txtred"; \
>         else \
>             PROMPT_PREFIX="$bldgrn$? "; \
>         fi '
> 
>     PS1='$(echo -ne "$PROMPT_PREFIX")'"\$\[$txtrst\] "

All non-printing character sequences must be enclosed in \[...\].

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    c...@case.edu    http://cnswww.cns.cwru.edu/~chet/


Reply via email to