![]() You only need to subtract the offset of your timezone from your local time to get UTC. How can I convert my/any local time into UTC? $ date -d ' 04:00 UTC' This would print: Thu Jun 7 00:00: for someone using Eastern Daylight Time. This conversion only works when you use a machine that is configured to display your time zone. You can use the command line tool date for this.A table with some time zone offsets is presented below. You need to know the offset of your timezone and add it to the current UTC time. ![]() You can find a long article about UTC at Wikipedia. Typical dates in UTC can look like these: For most timezones, this conversion uses integer multiples of hours (i.e. Localized times can be calculated through addition or subtraction to the current UTC time.
0 Comments
Leave a Reply. |