From 0b8b348366c7ca106ba3e52f5a886bb02eb43ff0 Mon Sep 17 00:00:00 2001 From: Kenneth Reitz Date: Fri, 16 Dec 2016 13:29:50 -0500 Subject: [PATCH] auto --- README.rst | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.rst b/README.rst index a842832..3f4d227 100644 --- a/README.rst +++ b/README.rst @@ -26,6 +26,11 @@ Just playing with an API here: >>> tomorrow.datetime() datetime.datetime(2016, 12, 16, 15, 11, 30, 263350, tzinfo=) + # Automatically parse datetime strings and generate naive datetimes. + >>> scraped = '2016-12-16 18:23:45.423992+00:00' + >>> maya.parse(scraped).datetime(to_timezone='US/Eastern', naive=True) + datetime.datetime(2016, 12, 16, 13, 23, 45, 423992) + >>> rand_day = maya.when('2011-02-07', timezone='US/Eastern') @@ -37,10 +42,7 @@ Just playing with an API here: >>> rand_day.timezone - # Automatically parse datetime strings and generate naive datetimes. - >>> scraped = '2016-12-16 18:23:45.423992+00:00' - >>> maya.parse(scraped).datetime(to_timezone='US/Eastern', naive=True) - datetime.datetime(2016, 12, 16, 13, 23, 45, 423992) + Timezones fit more in here somewhere...