Removed 'with' statement; it's available in Python2.5, but one needs to use the future import to do that, so easiest to remove it. Resolves issue 230.

This commit is contained in:
Griatch 2012-05-04 10:03:41 +02:00
parent 7058b9f210
commit c49fbd7d99
4 changed files with 13 additions and 9 deletions

View file

@ -15,8 +15,9 @@ sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
# Get Evennia version
#------------------------------------------------------------
try:
with open(os.pardir + os.sep + 'VERSION') as f:
VERSION = "%s-r%s" % (f.read().strip(), os.popen("hg id -i").read().strip())
f = open(os.pardir + os.sep + 'VERSION', 'r''')
VERSION = "%s-r%s" % (f.read().strip(), os.popen("hg id -i").read().strip())
f.close()
except IOError:
VERSION = "Unknown version"