Timezones Library
A Python library and CLI tool for getting current time in different timezones: PST, BST, WAT, CET, and EST.
Installation
pip install timezones-lib
Usage
Python Library
from timezones_lib import get_time_in_timezone, get_all_times
pst_time = get_time_in_timezone('PST')
print(f"PST: {pst_time}")
all_times = get_all_times()
for tz, time in all_times.items():
print(f"{tz}: {time}")
CLI Tool
tzlib --all
tzlib --timezone PST
tzlib
Supported Timezones
- PST: Pacific Standard Time (US/Pacific)
- BST: British Summer Time (Europe/London)
- WAT: West Africa Time (Africa/Lagos)
- CET: Central European Time (Europe/Berlin)
- EST: Eastern Standard Time (US/Eastern)
Development
Setup
git clone <repo-url>
cd timezones_lib
pip install -e .
Testing
python -m pytest tests/
Building
python -m build
License
MIT