|
From: | sci-fi |
Subject: | Re: still having cursor problems on MacOSX Terminal and iTerm |
Date: | Fri, 22 Dec 2006 12:22:50 -0600 |
User-agent: | Unison/1.7.7 |
On 2006-12-22 08:40:21 -0600, dearvoid <dearvoid@gmail.com> said:
On 12/22/06, sci-fi@hush.ai <sci-fi@hush.ai> wrote:On 2006-12-22 04:34:22 -0600, dearvoid <dearvoid@gmail.com> said: I will need to "close" each prompt line with an end-hilight code, do the \n, then begin the next line with a start-hilight code, such as: PS1='\[\e[0;7m\]\h[\w]\[\e[0m\]\n\[\e[0;7m\]\u\$\[\e[0m\] ' . ^^^^^^^^^ ^^^^^^^^^^^But do I put \[ \] around a \n (or include it there-in) ? Bash knows exactly what \n means in PS1 and can handle it well so we need not put \[ \] around \n . BTW: I also use MacOSX on my iBook G4.
It started sinking in that \n does affect the cursor position so it should not be put in the brackets. 'Twas late and the bash man-page just wasn't hitting any neurons in my old grey matter. Thank you for clarifying this, now I see what they mean. Things do "feel" better now. I've renamed Apple's /bin/bash and /bin/sh as a backup, then put symlinks to /usr/local/bin/bash, in effect this OSX box is now up on the latest & greatest bash for all uses. :) oh I've already tested it in single-user mode this way, works fine. Let's hope Apple uses this and other updated projects in Leopard, I wonder if it's too late to open bugreports requesting such, but I'd be running blind since I can't afford a $paid$ ADC membership to see what they're actually doing in the meantime. Thanks again. --
[Prev in Thread] | Current Thread | [Next in Thread] |