TZDIFF(1)

πŸ“¦
version 1.2.1 Β· 2 versions
, in debian trixie, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ TZDIFF(1) ✨

okay bestie, so the manual name is tzdiff β€” it's in section 1 (General Commands Manual), and it is literally the "what time is it over there" tool of your dreams. πŸ’–


🌸 NAME 🌸

tzdiff β€” shows you the timezone differences, side by side with your localtime. That's it, that's the whole vibe. πŸ•


πŸ¦‹ SYNOPSIS πŸ¦‹

tzdiff [-0lvHN] [-n count] [-f format] [-t start] timzone [timezone ...]
       [count] [0]
ngl bestie, timzone in there is exactly how the original spells it β€” not me being sloppy, that's a certified typo, and I am not fixing it because the rules say character-for-character. πŸ’€

πŸŽ€ DESCRIPTION πŸŽ€

So the tzdiff utility shows you the localtime of whatever timezone you name, plus yours, right next to each other. Iconic. Chef's kiss. πŸ‘‘

You need at least one timezone name, like Asia/Tokyo. And here's the cute part β€” if you just hand it something like Asia, tzdiff will show you all the timezones inside Asia, and then you get to pick one from the results. Very "let me scroll the menu" energy. πŸ“

tzdiff also supports completion on timezone names, because it wants you to thrive. So for example, Tok means Asia/Tokyo. Short king behavior, we love it. ✨

The options are as follows, and yes we're doing all of them, no skips:

  • -h β€” Show usage. (the classic "help meee" flag) πŸ™ˆ
  • -0 β€” Round down to hour. Also, 0 (zero) can be given as the last argument instead. ⏰
  • -l β€” Display the full timezone name (region/city). By default you only get the city.
  • -n count β€” Number of hours. Default is 10. Can also be given as the last argument.
  • -f format β€” Output format of the time. It uses the output format of date(1).
  • -t start β€” Specify the start time. For the GNU date command, you can specify a flexible format. Otherwise, it supports one of "YYYY-mm-ddTHH:HH[Z]", "YYYYmmddTHHMM[Z]" or "YYYYmmddHHMM[Z]" β€” and adding "Z" means UTC.
  • -v β€” Show version of tzdiff.
  • -H β€” Scripting mode with timezone name. In scripting mode, the field separator is TAB instead of space.
  • -HH β€” Scripting mode without timezone name.
  • -N β€” Display without local timezone.

πŸ’… EXAMPLES πŸ’…

All of these examples are running in JST, so keep that in mind bestie. 🫢

The command:

tzdiff

will display the result of ls -F /usr/share/zoneinfo:

Africa/       Australia/    Etc/          MST           WET
America/      CET           Europe/       MST7MDT       posixrules
--- snip --- snip --- snip ---
Asia/         EST           Indian/       SystemV/
Atlantic/     EST5EDT       MET           UTC

The command:

tzdiff Eu

will display the result of ls -F /usr/share/zoneinfo/Europe:

Europe/Amsterdam        Europe/Kiev             Europe/Sarajevo
Europe/Andorra          Europe/Kirov            Europe/Saratov
--- snip --- snip --- snip ---
Europe/Jersey           Europe/Samara
Europe/Kaliningrad      Europe/San_Marino

The command:

tzdiff Europe/Amsterdam

will display the time of CET and localtime.:

Amsterdam
2018-12-19 14:52 CET    2018-12-19 22:52 JST
2018-12-19 15:52 CET    2018-12-19 23:52 JST
--- snip --- snip --- snip ---
2018-12-19 22:52 CET    2018-12-20 06:52 JST
2018-12-19 23:52 CET    2018-12-20 07:52 JST

The command:

tzdiff Lond New_ 0 3

will display:

London                  New_York
2018-12-20 01:00 GMT    2018-12-19 20:00 EST    2018-12-20 10:00 JST
2018-12-20 02:00 GMT    2018-12-19 21:00 EST    2018-12-20 11:00 JST
2018-12-20 03:00 GMT    2018-12-19 22:00 EST    2018-12-20 12:00 JST
See how Lond and New_ did the completion thing AND 0 and 3 did the round-down + hour-count thing? ate. πŸ”₯

🌈 SEE ALSO 🌈

tzdiff on Github: https://github.com/belgianbeer/tzdiff β€” go give it a star, it's free πŸ’œ


πŸ‘‘ AUTHOR πŸ‘‘

Written by Masato Minda β€” thank you for your service, king 🫑


and that's a wrap bestie!! this lil page is from the <strong>Debian</strong> fam, version dated <strong>Jul 17, 2023</strong>. go check what time it is in Tokyo, mwah πŸ’–

πŸ“¦ where this page comes from