diff --git a/README.md b/README.md index 0aad852..a99ebac 100644 --- a/README.md +++ b/README.md @@ -7,11 +7,17 @@ Unix timestamp made easy. ```py from unix_time import * -now = ts_now() # 1568122835, 2019-09-10T13:40:35 -today = ts_today() # 1568073600, 2019-09-10T00:00:00 +now = ts_now() # 1568078625, 2019-09-10T01:23:45 + yesterday = ts_yesterday() # 1567987200, 2019-09-09T00:00:00 +today = ts_today() # 1568073600, 2019-09-10T00:00:00 +tomorrow = ts_tomorrow() # 1568160000, 2019-09-11T00:00:00 + +from datetime import datetime + +dt = datetime.fromisoformat('2019-09-10T01:23:45+00:00') -some_time = 1111111111 # 1111111111, 2005-03-18T01:58:31 -some_date = ts_date(some_time) # 1111104000, 2005-03-18T00:00:00 +date_plus_time = ts(dt) # 1568078625, 2019-09-10T01:23:45 +date_no_time = ts_date(dt) # 1568073600, 2019-09-10T00:00:00 ```