Files
ClaudeProjectManager/build_exe.py
Claude Project Manager 4dab418f2f Initial commit
2025-07-09 22:10:42 +02:00

48 Zeilen
1.6 KiB
Python

"""
Build executable for Claude Project Manager
"""
import PyInstaller.__main__
import os
import sys
def build_exe():
"""Build executable using PyInstaller"""
# Get the directory of this script
script_dir = os.path.dirname(os.path.abspath(__file__))
# PyInstaller arguments
args = [
'main.py', # Main script
'--name=ClaudeProjectManager', # Name of the executable
'--onefile', # Create a single executable file
'--windowed', # No console window
'--icon=NONE', # No icon for now
'--add-data=data;data', # Include data directory
'--add-data=gui;gui', # Include gui directory
'--add-data=utils;utils', # Include utils directory for logger
'--add-data=src;src', # Include src directory with gitea modules
'--hidden-import=customtkinter',
'--hidden-import=tkinter',
'--hidden-import=PIL',
'--hidden-import=packaging',
'--hidden-import=requests',
'--hidden-import=urllib3',
'--hidden-import=git',
'--collect-all=customtkinter', # Collect all customtkinter files
'--noconfirm', # Overwrite output directory without confirmation
'--clean', # Clean PyInstaller cache and remove temporary files
]
# Run PyInstaller
try:
PyInstaller.__main__.run(args)
print("\nBuild completed successfully!")
print(f"Executable can be found in: {os.path.join(script_dir, 'dist')}")
except Exception as e:
print(f"Build failed: {e}")
sys.exit(1)
if __name__ == "__main__":
build_exe()