File size: 1,223 Bytes
f81adc4
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/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..."