On Wed 20 Dec 2023 at 08:37:46 (+0100), to...@tuxteam.de wrote:
> On Wed, Dec 20, 2023 at 12:00:29AM -0600, David Wright wrote:
> 
> [...]
> 
> > Yes, I'm guessing that the OP is in my timezone, as just a few of
> > their previous posts have -5/-6 offsets. But most are +0, and
> > I wonder whether the OP ran this code on an all-UTC machine.
> > (IDK whether their using gmail is relevant.)
> 
> Nitpick and reminder: in UNIX and cousins, the "machine" has no
> timezone. It's the executable (and its children, if they don't
> change it). See:
> 
>   tomas@trotzki:~$ date
>   Wed Dec 20 08:24:32 CET 2023
>   tomas@trotzki:~$ TZ=Asia/Singapore bash
>   tomas@trotzki:~$ date
>   Wed Dec 20 15:24:47 +08 2023
>   tomas@trotzki:~$ exit
> 
> What is /etc/timezone for, then? you may ask.
> 
> It's just the default for when you don't pick any.

Sorry for the synecdoche, but I think it expresses the comprehensive
setting of UTC across the entirety of the computer and its operating
system, from the RTC, through /etc/timezone and /etc/localhost, to
the users' sessions. By this active (not just default) means, users
can remain blissfully unaware of the effects of setting timezones
other than UTC, just as the OP appeared to be, until reminded.

Obviously I have no idea what the OP's actual machine is set up for,
and I don't have any clue what their scheme is supposed to achieve.
Hence "I wonder whether …" quoted above.

Cheers,
David.

Reply via email to