diff --git a/main.py b/src/pydle.py similarity index 96% rename from main.py rename to src/pydle.py index 5c282ed..ad6907b 100644 --- a/main.py +++ b/src/pydle.py @@ -22,7 +22,7 @@ def resource_path(relative_path): def getWord(): - lines = open(resource_path('words.txt')).read().splitlines() + lines = open(resource_path('resource/words.txt')).read().splitlines() return random.choice(lines) diff --git a/src/pydle.spec b/src/pydle.spec new file mode 100644 index 0000000..189460b --- /dev/null +++ b/src/pydle.spec @@ -0,0 +1,40 @@ +# -*- mode: python ; coding: utf-8 -*- + + +block_cipher = None + + +a = Analysis(['pydle.py'], + pathex=[], + binaries=[], + datas=[('resource\\words.txt', '.')], + hiddenimports=[], + hookspath=[], + hooksconfig={}, + runtime_hooks=[], + excludes=[], + win_no_prefer_redirects=False, + win_private_assemblies=False, + cipher=block_cipher, + noarchive=False) +pyz = PYZ(a.pure, a.zipped_data, + cipher=block_cipher) + +exe = EXE(pyz, + a.scripts, + a.binaries, + a.zipfiles, + a.datas, + [], + name='pydle', + debug=False, + bootloader_ignore_signals=False, + strip=False, + upx=True, + upx_exclude=[], + runtime_tmpdir=None, + console=True, + disable_windowed_traceback=False, + target_arch=None, + codesign_identity=None, + entitlements_file=None ) diff --git a/words.txt b/src/resource/words.txt similarity index 100% rename from words.txt rename to src/resource/words.txt