diff options
author | Agustin Henze <tin@sluc.org.ar> | 2015-07-08 09:40:07 -0300 |
---|---|---|
committer | Agustin Henze <tin@sluc.org.ar> | 2015-07-08 09:40:07 -0300 |
commit | 87a1867a939926245c865249e701d48fa76f3a95 (patch) | |
tree | 9d383a37b63208fb80093bd60bc099f6e92e8710 | |
parent | 5571e71bdd34fbb0eb2851228a16ffebce743231 (diff) | |
download | nikola-87a1867a939926245c865249e701d48fa76f3a95.tar.bz2 nikola-87a1867a939926245c865249e701d48fa76f3a95.tar.xz nikola-87a1867a939926245c865249e701d48fa76f3a95.tar.zst |
Update patch (apply git revert aea500e7c9dfe7552728e10df126f285ccef3687
on upstream repo)
-rw-r--r-- | debian/patches/0002-Replace-strict-dependency-on-dateutil-for-the-current-one-in-debian.patch | 32 |
1 files changed, 31 insertions, 1 deletions
diff --git a/debian/patches/0002-Replace-strict-dependency-on-dateutil-for-the-current-one-in-debian.patch b/debian/patches/0002-Replace-strict-dependency-on-dateutil-for-the-current-one-in-debian.patch index 4403be4..8c9d19d 100644 --- a/debian/patches/0002-Replace-strict-dependency-on-dateutil-for-the-current-one-in-debian.patch +++ b/debian/patches/0002-Replace-strict-dependency-on-dateutil-for-the-current-one-in-debian.patch @@ -5,7 +5,37 @@ Pygments>=1.6 Pillow>=2.4.0 -python-dateutil==2.4.2 -+python-dateutil=>2.2 ++python-dateutil>=2.2 docutils>=0.12 mako>=1.0.0 unidecode>=0.04.16 +--- a/nikola/plugins/command/init.py ++++ b/nikola/plugins/command/init.py +@@ -355,15 +355,13 @@ + tz = dateutil.tz.gettz(answer) + + if tz is None: +- print(" WARNING: Time zone not found. Searching list of time zones for a match.") +- zonesfile = tarfile.open(fileobj=dateutil.zoneinfo.getzoneinfofile_stream()) ++ print(" WARNING: Time zone not found. Searching most common timezones for a match.") ++ zonesfile = tarfile.TarFile.open(os.path.join(dateutil.zoneinfo.ZONEINFOFILE)) + zonenames = [zone for zone in zonesfile.getnames() if answer.lower() in zone.lower()] + if len(zonenames) == 1: + tz = dateutil.tz.gettz(zonenames[0]) +- answer = zonenames[0] +- print(" Picking '{0}'.".format(answer)) + elif len(zonenames) > 1: +- print(" The following time zones match your query:") ++ print(" Could not pick one timezone. Choose one of the following:") + print(' ' + '\n '.join(zonenames)) + continue + +@@ -372,7 +370,7 @@ + print(" Current time in {0}: {1}".format(answer, time)) + answered = ask_yesno("Use this time zone?", True) + else: +- print(" ERROR: No matches found. Please try again.") ++ print(" ERROR: Time zone not found. Please try again. Time zones are case-sensitive.") + + SAMPLE_CONF['TIMEZONE'] = answer + |