first line overwritten in Bash

Randall R Schulz rrschulz@cris.com
Sat Apr 12 04:26:00 GMT 2003


Luciano,

You're not signalling BASH (and the readline library it uses) which 
portions of that prompt do not produce characters on the screen. That 
causes it to lose track of where the cursor really is when the prompt 
is printed. Any non-printing sequence in PS1 should be surrounded by \[ 
and \]. See the PROMPTING section of the BASH manual for more details.

Randall Schulz


At 17:42 2003-04-11, Luciano wrote:
>I customized my prompt in Bash, but it is not working.
>
>PS1='\033[38;1m\][\!]\W> \033[0m\]'
>
>When I type and reach the end of the first line, it continues on the
>same line, overwriting what is already there. The subsequent lines
>are typed correctly. It only happens with rxvt. In pure DOS console,
>though, my prompt has smiling face symbols on either side. What have
>I done wrong?
>
>Thanks,
>
>Luciano ES


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list