Skip to content

nikoladze/worldclock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 

Repository files navigation

Small script to show the time around the world using python-dateutil

The default list of timezones is hardcoded on top of the script - adjust it to your needs.

I'm no expert in timezones and the tz database. Let me know if something is wrong in the script or can be improved.

Useful links: https://xkcd.com/now, https://en.wikipedia.org/wiki/List_of_tz_database_time_zones

Install

pipx install git+https://github.com/nikoladze/worldclock

Examples

Show the current time in different time zones

worldclock

Show the time in different time zones at 12:00 US central time

worldclock 12:00 CST

Times are parsed with dateutil.parse.parser - supports different notations, e.g.

worldclock 2 pm CST
worldclock 14:00 CST
worldclock 14:00 -5
worldclock 2023-10-30 14:00 CST

Show additional time zones

worldclock --extra-list America/Mexico_City America/Cancun

Show only specific time zones

worldclock --only Africa/Nairobi Africa/Lagos
worldclock --only CST CET JST

Show info on daylight saving time (if observed and until when)

worldclock --dst

List all timezones and their utc offsets

worldclock --list

About

Small script to show time around the world

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages