It is explained here in the tzset () code:
The TZ environment variable is expected to be in the following POSIX
where: std is the name of the standard time-zone (minimum 3 chars)
offset1 is the value to add to local time to arrive at Universal time
it has the form: hh[:mm[:ss]]
dst is the name of the alternate (daylight-savings) time-zone (min 3 chars)
offset2 is the value to add to local time to arrive at Universal time
it has the same format as the std offset
start is the day that the alternate time-zone starts
time1 is the optional time that the alternate time-zone starts
(this is in local time and defaults to 02:00:00 if not specified)
end is the day that the alternate time-zone ends
time2 is the time that the alternate time-zone ends
(it is in local time and defaults to 02:00:00 if not specified)
Note that there is no white-space padding between fields. Also note that
if TZ is null, the default is Universal GMT which has no daylight-savings
time. If TZ is empty, the default EST5EDT is used.
This requires understanding Unix-style documentation of arguments. Specifically, optional arguments are enclosed in ‘’.
So, when DST is ignored:
Is reduced to
The name for the time zone:
The offset is:
Combined, stdoffset1 is “ "Europe/Berlin1", or “Europe/Berlin+1”, but the ‘+’ should not be necessary.
I've just tried your suggestions, Perhaps I just need more time then I expected for this point. Because I update the time using GPS parsed information in other task too, which potentially poluting the time setting. With your advice I changed my timezone name to "Europe/Berlin1"
, and tryed to deploy localtime
to get the timezone specified time. Still without difference as before.
And I talked to my colleage either. They suggested me not rely on this timestamp, because the end user always has a computer that as old as they are (> 50 years old), and the Cell battery for BIOS time holding would never works. Which alway cause problems
So just let the end user specify their file editing time BY HAND.
Code: Select all
Should make everyone happy at last.
But Thans tele_player for the information though! If I have time later. I'll figure out why the problem stay the same!