#!/bin/bash # Move to the directory where the script is located cd "$(dirname "$0")" echo "------------------------------------------" echo "Starting build process for your app..." echo "------------------------------------------" # Try to use the virtual environment if [ -d "venv" ]; then echo "Using virtual environment..." ./venv/bin/pip install pyinstaller ./venv/bin/pyinstaller --noconfirm --onefile --windowed \ --add-data "nvidia_nim_models.json:." \ --add-data ".env.example:." \ --name "FreeClaudeProxy" \ --collect-all fastapi \ --collect-all uvicorn \ desktop_app.py else echo "Virtual environment not found, trying system python..." pip3 install pyinstaller pyinstaller --noconfirm --onefile --windowed \ --add-data "nvidia_nim_models.json:." \ --add-data ".env.example:." \ --name "FreeClaudeProxy" \ --collect-all fastapi \ --collect-all uvicorn \ desktop_app.py fi echo "------------------------------------------" echo "DONE! Your app is in the 'dist' folder." echo "You can close this window now." echo "------------------------------------------" read -p "Press enter to exit..."