1
0

windows: build portable version without patching the source

This commit is contained in:
ThomasV
2017-11-28 18:20:14 +01:00
parent 3e72e7a3f0
commit b9d8b2a571
4 changed files with 49 additions and 55 deletions

View File

@@ -316,7 +316,7 @@ if __name__ == '__main__':
elif arg == '?':
sys.argv[i] = input("Enter argument:")
elif arg == ':':
sys.argv[i] = prompt_password('Enter argument (will noot echo):', False)
sys.argv[i] = prompt_password('Enter argument (will not echo):', False)
# parse command line
parser = get_parser()
@@ -338,6 +338,10 @@ if __name__ == '__main__':
config_options['cwd'] = os.getcwd()
# fixme: this can probably be achieved with a runtime hook (pyinstaller)
if is_bundle and os.path.exists(os.path.join(sys._MEIPASS, 'is_portable')):
config_options.get('portable') = True
if config_options.get('portable'):
config_options['electrum_path'] = os.path.join(os.path.dirname(os.path.realpath(__file__)), 'electrum_data')