Friendly Dates and Times
Project description
User-friendly functions to help perform common date and time actions.
Usage
To get the system time zone’s name:
when.timezone()
To get the current date:
when.today()
To get tomorrow’s date:
when.tomorrow()
To get yesterday’s date:
when.yesterday()
To get a datetime one year from now:
when.future(years=1)
To convert to a different time zone:
when.shift(value, from_tz='America/New_York', to_tz='UTC')
To get the current time:
when.now()
Full documentation can be found on Read the Docs._
Installation
Installing When.py is easy:
pip install whenpy
or download the source and run:
python setup.py install
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
whenpy-0.1.1.tar.gz
(6.8 kB
view details)
File details
Details for the file whenpy-0.1.1.tar.gz
.
File metadata
- Download URL: whenpy-0.1.1.tar.gz
- Upload date:
- Size: 6.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 30b0952c28029d56bb0050777fe161b6f56fdd77cbf075f8e04c3c57af0fe41b |
|
MD5 | 324d083659366c14614039a011a70550 |
|
BLAKE2b-256 | 96031d32093eb99fda1199c7bd338598a70645b2dc08716360793c4c14b0f054 |