Improve script to be run from anywhere

bzr revid: ced-a6ca1ebcbfadb0b553e12d37f1f67086a8044571
This commit is contained in:
ced
2007-08-29 14:19:28 +00:00
parent 9cc957d840
commit c649985382
@@ -1,5 +1,5 @@
#!/usr/bin/python
#coding: latin-1
#coding: utf-8
##############################################################################
#
@@ -357,7 +357,7 @@ if __name__ == "__main__":
fname = sys.argv[1]
f = StringIO.StringIO(file(fname).read())
xsl = file('normalized_oo2rml.xsl').read()
xsl = file(os.path.join(os.getcwd(), os.path.dirname(sys.argv[0]), 'normalized_oo2rml.xsl')).read()
result = sxw2rml(f, xsl, output=opt.output, save_pict=False)
print result