On Mon, 18 May 2020 09:38:01 -0400, Steve Smith wrote:
>Speaking of TZ, by coincidence I just stumbled across its full
>documentation in UNIX System Services Command Reference Appendix I.
>
>Format
>TZ= standardHH[:MM[:SS]] [daylight[HH[:MM[:SS:]]]
>[,startdate[/starttime],enddate[/endtime]] ]
>
>It describes all those elements. I wasn't even aware of the DST rules
>part. I'll probably not get this right, but I calculate the full US ET
>string as TZ=EST05EDT04,M3.2.0,M11.1.0
>
>Maybe fetching TZ would solve the original problem. And maybe it would be
>easier to just take a parm.
>
FWIW, the POSIX forms appear as the last lines of tzdata entries and can
be extracted on Linux or other modern systems with the command:
( cd /usr/share/zoneinfo && find . -name posix -prune -o -name right
-prune -o -type f -exec printf %s\\t {} \; -exec tail -1 {} \; )
...
./America/Regina CST6
./America/Cuiaba <-04>4
./America/Maceio <-03>3
./America/Montreal EST5EDT,M3.2.0,M11.1.0
./America/Blanc-Sablon AST4
./America/Cambridge_Bay MST7MDT,M3.2.0,M11.1.0
./America/Bogota <-05>5
./America/Iqaluit EST5EDT,M3.2.0,M11.1.0
./America/Mendoza <-03>3
...
Hammer and file to fit.
--gil
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN