how can I change timezone on MSYS+MinGW for Windows if I have only “date” command installed? There are no “tzconfig” or “tzselect” here.
When I try $date –set=”Apr 01 23:08 UTC+04:00″
I receive 19:08 GMT+0 result.
This is very important for me because “make” command always gives me errors about files modified in future.
I had the same issue. My timezone is CET (GMT+1).
I have fixed this by setting environment variable TZ, like so:
Before setting the variable I had:
(dos prompt)
(msys shell)
After setting TZ=CET-1CEST it becomes:
(dos prompt)
(msys shell)
The fields in this variable are
Note that the first and third field are just used to display in the date string. You can just as well set it to FOO and BAR if you like, it’s the second (and optionally fourth) field that do the actual time modification.
The parameter can take even more fields to define when DST starts and ends. If you like to read more about it, see this page.