From 5ec02211214350ee558fd9f6bb052264fd24f75e Mon Sep 17 00:00:00 2001 From: Agustin Henze Date: Tue, 21 Oct 2014 10:33:15 -0300 Subject: Imported Upstream version 7.1.0 --- nikola/plugins/command/init.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'nikola/plugins/command/init.py') diff --git a/nikola/plugins/command/init.py b/nikola/plugins/command/init.py index 8fb15e0..a8b60db 100644 --- a/nikola/plugins/command/init.py +++ b/nikola/plugins/command/init.py @@ -27,7 +27,7 @@ from __future__ import print_function, unicode_literals import os import shutil -import codecs +import io import json import textwrap import datetime @@ -242,7 +242,7 @@ class CommandInit(Command): template_path = resource_filename('nikola', 'conf.py.in') conf_template = Template(filename=template_path) conf_path = os.path.join(target, 'conf.py') - with codecs.open(conf_path, 'w+', 'utf8') as fd: + with io.open(conf_path, 'w+', encoding='utf8') as fd: fd.write(conf_template.render(**prepare_config(SAMPLE_CONF))) @classmethod -- cgit v1.2.3