bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

\e in PS1


From: Andy Goth
Subject: \e in PS1
Date: Tue, 5 Aug 2003 03:19:05 -0500
User-agent: KMail/1.5.1

I'm having a problem with escape sequences in my PS1:

\[\e[1;30m\][\[\e[31m\]\u\[\e[30m\]@\[\e[32m\]\h\[\e[30m\]|\[\e[34m\]\w\[\e[30m\]]\[\e[35m\]\$\[\e[0m\]
 
(has a space at the end)

I \[...\] bracketed all the escape sequences, yet I still experience the 
problem described in bash FAQ E3, UNLESS I'm using TERM={linux,vt100}.  With 
TERM={xterm,rxvt,konsole} bash/readline misbehaves.  I'm not sure about other 
TERM types.  I experience this with several GNU/Linux-based systems and I 
think I also get it with PuTTY in MS-Windows (will check again later).

With PS1='[\u@\h|\w]\$ ' all the problems go away regardless of my TERM.

Output of bashbug on this system:

Machine: i686
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='i686' -                  
DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i686-pc-linux-gnu' -                  
DCONF_VENDOR='pc' -DSHELL -DHAVE_CONFIG_H  -D_FILE_OFFSET_BITS=64  -I.  -I. 
-I./include -I./lib -I/usr/include -O9 -march=i686 -mcpu=i686
uname output: Linux chainsaw 2.4.21 #2 Sat Jun 28 19:56:24 CDT 2003 i686 
unknown
Machine Type: i686-pc-linux-gnu

Bash Version: 2.05
Patch Level: 0
Release Status: release

-- 
Andy Goth  |  unununium@openverse.com  |  http://ioioio.net/
Engineers love to change things.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]