Re: Screen Corruption when browsing Command History with Custom Prompt

2008-09-09 Thread Ashley Wilson
On Wed, Sep 10, 2008 at 3:02 AM, Matthew Woehlke <[EMAIL PROTECTED]> wrote: > Ashley Wilson wrote: >> >> No, Wait! That's not the issue!! This works just fine: >> >> PS1="\n\[\e[0;32m\]\u: \w\n# \[\e[m\]" >> >> So, all I had to do was to add '\[' before and '\]' after the coloring >> sequen

Re: Screen Corruption when browsing Command History with Custom Prompt

2008-09-09 Thread Matthew Woehlke
Ashley Wilson wrote: No, Wait! That's not the issue!! This works just fine: PS1="\n\[\e[0;32m\]\u: \w\n# \[\e[m\]" So, all I had to do was to add '\[' before and '\]' after the coloring sequence to fix everything! Of course it works; this is exactly what Chet was trying to tell you.

Re: Screen Corruption when browsing Command History with Custom Prompt

2008-09-09 Thread Ashley Wilson
No, Wait! That's not the issue!! This works just fine: PS1="\n\[\e[0;32m\]\u: \w\n# \[\e[m\]" So, all I had to do was to add '\[' before and '\]' after the coloring sequence to fix everything! -- Regards, Ashley. On Wed, Sep 10, 2008 at 12:51 AM, Ashley Wilson <[EMAIL PROTECTED]> wr

Re: Screen Corruption when browsing Command History with Custom Prompt

2008-09-09 Thread Ashley Wilson
The escape sequence for adding colors are an exception - If you add backslashes to those brackets, it won't (and doesn't) work as expected. I tried what you said : Set PS1 = "\n\e\[0;31m\u: \w\n# \e\[m" The resulting prompt did, still, exhibit the corruption explained in my bug repor

Re: Screen Corruption when browsing Command History with Custom Prompt

2008-09-09 Thread Chet Ramey
Ashley Wilson wrote: Repeat-By: Set a custom prompt using the PS1 variable as follows: PS1="\n\e[0;31m\u: \w\n# \e[m" Then, browse command history using up/down keys. As the documentation states, you need to bracket sequences of non-printing c