What time is it?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm one of those folks who likes to set her bash prompt in a particular
way. My [particular thing is to have the time provided in the prompt.
Ofr course, that's only the time as of when the command prompt is
returned, but that is actually helpful to me. In part, I like this
because I travel a good deal, and it's useful to have the current local
time displayed frequently.

Problem is, it doesn't work. It used to, but no longer, and I don't know
exactly when or how it got broken.

Some facts:

I'm running Red Hat 8.0 (fully updated). That's bash version:

GNU bash, version 2.05b.0(1)-release (i686-pc-linux-gnu)
I have the following prompt string defined:

PS1="[\u@\h \t] \W\\\$"

And, indeed, this displays the current time. But, it doesn't track time
zone changes. For example, I'm currently writing from L.A., so I have:

export "TZ=US/Pacific" #Pacific Time


And, indeed, issuing the 'date' command reflects this:

Mon Feb 17 19:19:38 PST 2003
[janina at toccata 22:19:38] janina$

But, as you can plainly see, the prompt comes back in Eastern Time, not
Pacific. What's wrong? How do I fix it?

Or, am I supposed to stay home and not miss blizzards?? <grin>


-- 
	
				Janina Sajka, Director
				Technology Research and Development
				Governmental Relations Group
				American Foundation for the Blind (AFB)

Email: janina at afb.net		Phone: (202) 408-8175




[Index of Archives]     [Linux for the Blind]     [Fedora Discussioin]     [Linux Kernel]     [Yosemite News]     [Big List of Linux Books]
  Powered by Linux