Still regarding portable mode path fixes
This commit is contained in:
mailchuck 2015-12-13 22:18:31 +01:00 committed by Peter Surda
parent 5a45d7dd8f
commit 8136b022bc
2 changed files with 4 additions and 4 deletions

View File

@ -35,7 +35,7 @@ def loadConfig():
needToCreateKeysFile = True needToCreateKeysFile = True
else: else:
shared.config.read(shared.lookupExeFolder() + 'keys.dat')) shared.config.read(shared.lookupExeFolder() + 'keys.dat')
try: try:
shared.config.get('bitmessagesettings', 'settingsversion') shared.config.get('bitmessagesettings', 'settingsversion')
print 'Loading config files from same directory as program.' print 'Loading config files from same directory as program.'

View File

@ -200,9 +200,9 @@ def assembleErrorMessage(fatal=0, banTime=0, inventoryVector='', errorText=''):
def lookupExeFolder(): def lookupExeFolder():
if frozen: if frozen:
exeFolder = os.path.join(os.path.dirname(sys.executable), '/') exeFolder = path.dirname(sys.executable) + path.sep
elif __file__: elif __file__:
exeFolder = os.path.join(os.path.dirname(__file__), '/') exeFolder = path.dirname(__file__) + path.sep
else: else:
exeFolder = '' exeFolder = ''
return exeFolder return exeFolder