The fancy copying stuff didn't work. Simplified the .spec.
This commit is contained in:
@@ -1,6 +1,4 @@
|
||||
# -*- mode: python ; coding: utf-8 -*-
|
||||
import shutil
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
a = Analysis(
|
||||
@@ -50,28 +48,3 @@ coll = COLLECT(
|
||||
name='Toby Doom Launcher',
|
||||
)
|
||||
|
||||
# Post-build hook: Copy nvdaControllerClient.dll to _internal and copy/rename docs
|
||||
build_dir = Path('build') / 'Toby Doom Launcher'
|
||||
internal_dir = build_dir / '_internal'
|
||||
|
||||
# Copy NVDA DLL to _internal
|
||||
nvda_dll_source = Path('nvdaControllerClient.dll')
|
||||
nvda_dll_dest = internal_dir / 'nvdaControllerClient.dll'
|
||||
if nvda_dll_source.exists() and internal_dir.exists():
|
||||
shutil.copy2(str(nvda_dll_source), str(nvda_dll_dest))
|
||||
print('✓ Copied nvdaControllerClient.dll to build/Toby Doom Launcher/_internal/')
|
||||
|
||||
# Copy and rename LICENSE file
|
||||
license_source = Path('LICENSE')
|
||||
license_dest = build_dir / 'toby-doom-launcher_LICENSE.txt'
|
||||
if license_source.exists() and build_dir.exists():
|
||||
shutil.copy2(str(license_source), str(license_dest))
|
||||
print('✓ Copied LICENSE to build/Toby Doom Launcher/toby-doom-launcher_LICENSE.txt')
|
||||
|
||||
# Copy and rename README file
|
||||
readme_source = Path('README.md')
|
||||
readme_dest = build_dir / 'toby-doom-launcher_README.md'
|
||||
if readme_source.exists() and build_dir.exists():
|
||||
shutil.copy2(str(readme_source), str(readme_dest))
|
||||
print('✓ Copied README.md to build/Toby Doom Launcher/toby-doom-launcher_README.md')
|
||||
|
||||
|
||||
Reference in New Issue
Block a user