Changing single user's timezone on UNIX

Date 2005/10/10 9:23:49 | Topic: Bur

Since I started using the services of silenceisdefeat.org (very cheap shell access + web/mail/etc.), I had but one issue - the server is somewhere in the US, so the time shown is in a different timezone. This created quite a mess in my ICQ and IRC logs (both of which I use from this server). I never had to deal with this problem before, and searching for a solution was not as easy as it might seem.

Solution, as is usually the case in most *n*x systems, exists and is pretty simple (once you know what to look for). All it takes is to set environment (shell) variable called "TZ" to the three-letter code of the timezone you are in. In my case, all I did was to add the line
export TZ=CET
into my .profile

Now (to my surprise) both CenterICQ and IRSSI honor this setting and show the correct time. I hope this helps someone with a simillar problem.


This article comes from portal.vakoveverky.net - Just another social portal for geeks and their friends
http://portal.vakoveverky.net

The URL for this story is:
http://portal.vakoveverky.net/article.php?storyid=20