Commit 3ec753d0 authored by Anders Blomdell's avatar Anders Blomdell
Browse files

Changed encoding to utf-8

parent ab67bb2a
......@@ -3,6 +3,6 @@ TARGETS: hostinfo
all: $(TARGETS)
hostinfo: src/hostinfo.py $(wildcard src/hostinfo/*.py) Makefile
hostinfo: src/hostinfo.py $(sort $(wildcard src/hostinfo/*.py)) Makefile
(cd src ; apa -o ../$@ $(filter %.py, $(^:src/%=%)))
......@@ -325,7 +325,7 @@ if __name__ == '__main__':
if options.mio:
mio = hostinfo.mio.generate(tree)
print mio.encode("iso8859-1")
print mio.encode("utf-8")
if options.named:
for (f, c) in hostinfo.named.generate(tree, options):
......@@ -371,7 +371,7 @@ if __name__ == '__main__':
f = open(name)
conf = f.read()
f.close()
write = conf != file[name].encode("iso8859-1")
write = conf != file[name].encode("utf-8")
except IOError, e:
write = True
......@@ -379,7 +379,7 @@ if __name__ == '__main__':
print name
result = 0
f = open(name, "w")
f.write(file[name].encode("iso8859-1"))
f.write(file[name].encode("utf-8"))
f.close()
for name in symlink.keys():
......
......@@ -2,7 +2,7 @@ import copy
import hostinfo
def generate(tree):
result = "<?xml version='1.0' encoding='iso8859-1'?>\n\n"
result = "<?xml version='1.0' encoding='utf-8'?>\n\n"
mio = hostinfo.parser.Node("mio")
for m in tree._mio_:
mio = copy.deepcopy(m)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment