Menu
blog.headdesk.me
blog.headdesk.me

Getting time in a different time zone

Posted on 2015/01/092021/07/24

These come in handy as I frequently need to know  the time in different timezone.

To get the current time in a different timezone, specify the TZ variable

[bash]
$ TZ=US/Pacific date
Thu Jan  8 17:57:08 PST 2015
[/bash]

To get the time of your choice

[bash]
$ date –date=’TZ=”US/Pacific” 01:00′
Fri Jan 9 17:00:00 HKT 2015
[/bash]

facebookShare on Facebook
TwitterTweet

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Full text search

Recent Posts

  • Terraform and segregated permissions
  • LVM Compression and Deduplication
  • Edit gpg encrypted file with vim
  • Lelit Elizabeth PL92T Pressure Tuning
  • jq transformation
  • aws (8)
  • coffee (1)
  • headfi (1)
  • linux (6)
  • others (58)
  • security (2)
  • tech (36)
  • wordpress (2)

apache aws awscli azure backup clearlinux cloud coffee docker DOCP ec2 EL8 epyc espresso featured gpg jenkins kernel lelit linux lvm meltdown memory MFA mikrotik php python rdp Redhat RHEL roasting rpm Ryzen site-to-site snapshot spectre tech terraform tuning ubuntu ubuntu upgrade vim vpn wordpress xdotool

©2023 blog.headdesk.me | Powered by SuperbThemes & WordPress