From 53ec348a897d392ae7123efa77d7d5cc3455e19e Mon Sep 17 00:00:00 2001 From: Gunnar Wrobel Date: Tue, 11 Sep 2007 09:34:48 +0000 Subject: Layman v1.1 --- overlay.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'overlay.py') diff --git a/overlay.py b/overlay.py index 38e9364..ffbf32f 100644 --- a/overlay.py +++ b/overlay.py @@ -24,7 +24,7 @@ __version__ = "$Id: overlay.py 273 2006-12-30 15:54:50Z wrobel $" # #------------------------------------------------------------------------------- -import os, os.path, xml.dom.minidom +import sys, codecs, os, os.path, xml.dom.minidom from layman.overlays.bzr import BzrOverlay from layman.overlays.darcs import DarcsOverlay @@ -161,7 +161,7 @@ class Overlays: try: - out_file = open(path, 'w') + out_file = codecs.open(path, 'w', 'utf-8') doc.writexml(out_file, '', ' ', '\n') @@ -178,7 +178,6 @@ class Overlays: >>> a.select('wrobel-stable').data['&src'] u'rsync://gunnarwrobel.de/wrobel-stable' ''' - if overlay in self.overlays.keys(): return self.overlays[overlay] -- cgit v1.2.3-1-g7c22