From 09228968ea44fb8350b02efce16a121ef99c49be Mon Sep 17 00:00:00 2001 From: Christopher Dunn Date: Wed, 10 Sep 2014 17:26:46 -0700 Subject: [PATCH] fix for python2 --- amalgamate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/amalgamate.py b/amalgamate.py index 5b9d220..9e3f08c 100644 --- a/amalgamate.py +++ b/amalgamate.py @@ -44,7 +44,7 @@ class AmalgamationFile: if output_dir and not os.path.isdir( output_dir ): os.makedirs( output_dir ) f = open( output_path, "wb" ) - f.write( bytes(self.get_value(), 'UTF-8') ) + f.write( str.encode(self.get_value(), 'UTF-8') ) f.close() def amalgamate_source( source_top_dir=None,