Hmm, interesting.  I thought that using "env | grep PROM" would show
PROMPT_COMMAND's value, but I guess not.  Yes, I do have PROMPT_COMMAND
set, it appears.  However, if I unset it (and even also 'export PS1="foo
"' to set PS1 to a simple string), the problem remains.

How best to debug this?  tcsh and sh do not exhibit the problem, and it
only seems to happen on Gentoo/FreeBSD (not Linux).

                                        -Joe


Benno Schulenberg wrote:
> Giraud wrote:
>> The following prompt is set in my .bashrc (but the same behavior
>> happens if I do not set it or set it to a simple string, so I
>> don't think this matters):
>>
>>      PS1="\[\033[33m\]\h-\u\[\033[36m\] [\w] (\!)\[\033[00m\] "
>>
>> PROMPT_COMMAND is not set.
> 
> Look at your typescript with vim.  You'll see this gets printed:
> 
>    ^[]0;[EMAIL PROTECTED]:~^G^[[?1034h
> 
> before your prompt is printed:
> 
>    ^[[33mcrater-joe^[[36m [~] (500)^[[00m 
> 
> Where is that first string coming from if not from PROMPT_COMMAND?  
> It looks suspiciously similar to what Gentoo sets as prompt command 
> in /etc/bash/bashrc.  :)  Except for this "^[[?1034h" at the end.
> Where is that coming from?  It does strange things with the width of 
> the terminal when I add it here to PS1.  So when you get rid of it, 
> things might work correctly again.
> 
> Benno
> 
> 


_______________________________________________
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-bash

Reply via email to