Permalink
Browse files

Fixed unicode issues in ubuntu when writing the script

  • Loading branch information...
1 parent b33bbf0 commit 45c56f6cd9402eeeae0741d1afe66f4212f33ad6 @magicaltrevor magicaltrevor committed Sep 20, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 blueprint/frontend/sh.py
@@ -10,7 +10,7 @@
import re
from shutil import copyfile
import tarfile
-
+import unicodedata
from blueprint import git
from blueprint import util
@@ -327,6 +327,8 @@ def dumpf(self, gzip=False):
# Write the actual shell code.
for out in self.out:
+ if type(out) == unicode:
+ out = unicodedata.normalize('NFKD', out).encode('utf-8', 'ignore')
f.write('{0}\n'.format(out))
f.close()

0 comments on commit 45c56f6

Please sign in to comment.