Re: TZ=... date affected PROMPT_COMMAND

2008-04-18 Thread jidanni
OK, glad that it is fixed in bashes beyond what Debian sid uses. M> you still didn't answer my question, which was "what version are you using"? Did too: >> 02:26 /$ echo $BASH_VERSION >> 3.1.17(1)-release Over and out.

Re: TZ=... date affected PROMPT_COMMAND

2008-04-17 Thread Matthew Woehlke
Chet Ramey wrote: Assuming you're using bash-3.1.x, that could, as Chet suggested, be the problem; I don't have a 3.1 handy to test. It is the problem. I'll take your word for it. You had previously stated that 3.2 fixed something, but not if "something" was introduced in 3.1, so I wasn't s

Re: TZ=... date affected PROMPT_COMMAND

2008-04-17 Thread Chet Ramey
> Assuming you're using bash-3.1.x, that could, as Chet suggested, be the > problem; I don't have a 3.1 handy to test. It is the problem. Chet -- ``The lyf so short, the craft so long to lerne.'' - Chaucer Chet Ramey, ITS, CWRU[EMAIL PROTECTED]http://tiswww.tis.case.edu/~chet/

Re: TZ=... date affected PROMPT_COMMAND

2008-04-17 Thread Matthew Woehlke
[EMAIL PROTECTED] wrote: OK, now using Archimerged's cleaner version, I bet Matthew can reproduce this. Nope, and you still didn't answer my question, which was "what version are you using"? I'm going to guess all that is needed to reproduce for you is 'PS1="\W\$ "'. Assuming you're using b

Re: TZ=... date affected PROMPT_COMMAND

2008-04-17 Thread Chet Ramey
[EMAIL PROTECTED] wrote: OK, now using Archimerged's cleaner version, I bet Matthew can reproduce this. [EMAIL PROTECTED]:/root# su - nobody No directory, logging in with HOME=/ [EMAIL PROTECTED]:/$ PROMPT_COMMAND='prompt_status=\ $?' [EMAIL PROTECTED]:/$ PS1=$SPECIAL_PS1"\A\${prompt_status# 0}

Re: TZ=... date affected PROMPT_COMMAND

2008-04-17 Thread jidanni
OK, now using Archimerged's cleaner version, I bet Matthew can reproduce this. [EMAIL PROTECTED]:/root# su - nobody No directory, logging in with HOME=/ [EMAIL PROTECTED]:/$ PROMPT_COMMAND='prompt_status=\ $?' [EMAIL PROTECTED]:/$ PS1=$SPECIAL_PS1"\A\${prompt_status# 0} \W$ " 17:26 /$ TZ=America/L

Re: TZ=... date affected PROMPT_COMMAND

2008-04-16 Thread Archimerged Ark Submedes
This version works the same as the more verbose one: PROMPT_COMMAND='prompt_status=\ $?' PS1=$SPECIAL_PS1"$my_color_on\A\${prompt_status# 0} \W\$$my_color_off " Putting the variables inside $(...) avoids global variables and use of PROMPT_COMMAND: PS1='\A$(S=$?; W=$((S>99?4:(S>9?3:(S>0?2:0;

Re: TZ=... date affected PROMPT_COMMAND

2008-04-16 Thread Matthew Woehlke
[EMAIL PROTECTED] wrote: Never thought that putting TZ here would infect my prompt, 21:07 ~$ date Wed Apr 16 21:07:54 CST 2008 21:07 ~$ TZ=America/Chicago date Wed Apr 16 08:08:07 CDT 2008 08:08 ~$ set a b c 08:08 ~$ date Wed Apr 16 21:08:22 CST 2008 21:08 ~$ all the way until the next non buil