From 259c7a4b4e263e679fda41c259fa9c96ccc03746 Mon Sep 17 00:00:00 2001 From: Pouria Hadjibagheri Date: Sun, 23 Apr 2017 10:40:05 +0100 Subject: [PATCH] Python 2 compatibility. --- dev.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dev.py b/dev.py index b8e5958..5bd6fc5 100644 --- a/dev.py +++ b/dev.py @@ -167,11 +167,11 @@ def create_files(name): file.find('contents').text = escape(file_io) elif not contents_identical: with open(absolute_path, mode='w') as file_io: - print(template_contents, file=file_io, end='\n') + file_io.write(template_contents + '\n') print('> REPLACED with default:', display_path) else: with open(absolute_path, mode='w') as target_file: - print(template_contents, file=target_file) + target_file.write(template_contents) print('> CREATED:', display_path) contents_xml.write(