Re: [OT] Bold prompts in bash (SOLVED: Problem with /usr/X11R6/bin/xterm)
Re: [OT] Bold prompts in bash (SOLVED: Problem with /usr/X11R6/bin/xterm)
- Subject: Re: [OT] Bold prompts in bash (SOLVED: Problem with /usr/X11R6/bin/xterm)
- From: "Cook, Rich" <email@hidden>
- Date: Tue, 7 Dec 2010 17:00:01 -0800
- Acceptlanguage: en-US
- Thread-topic: [OT] Bold prompts in bash (SOLVED: Problem with /usr/X11R6/bin/xterm)
You are correct, sorry if my explanation was unclear.
On Dec 7, 2010, at 1:49 AM, Harald Hanche-Olsen wrote:
> + "Cook, Rich" <email@hidden>:
>
>> AHA! I unset PS1 variable and the problem is gone.
>> Here is what it was set to:
>>
>> cook47@rcmac (cuda-install): echo $PS1
>> \e[37;40;1m\[\033]0;\u@\h (\w)\007\]\u@\h (\W):
>
> The \[...\] construct is supposed to help with that, but you're using
> it in a funny way. You're supposed to put every part of the prompt
> that does not contribute to the width of the prompt inside, the rest
> outside. See the PROMPTING section of the bash man page.
>
> (I don't use bash myself, but a bit of googling led me to
>
> http://www.tek-tips.com/viewthread.cfm?qid=1560209&page=12
>
> which explains it some.)
>
> - Harald
--
✐Richard Cook
✇ Lawrence Livermore National Laboratory
Bldg-453 Rm-4024, Mail Stop L-557
7000 East Avenue, Livermore, CA, 94550, USA
☎ (office) (925) 423-9605
☎ (fax) (925) 423-6961
---
Information Management & Graphics Grp., Services & Development Div., Integrated Computing & Communications Dept.
(opinions expressed herein are mine and not those of LLNL)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list (email@hidden)
This email sent to email@hidden