1+ name : Build and Release Executables
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*.*.*'
7+
8+ jobs :
9+ build :
10+ name : Build ${{ matrix.os }}
11+ runs-on : ${{ matrix.os }}
12+ strategy :
13+ matrix :
14+ include :
15+ - os : windows-latest
16+ name : KickDropMiner-Windows.exe
17+ command : --onefile --windowed --name KickDropMiner --icon=static/favicon.ico
18+ - os : ubuntu-latest
19+ name : KickDropMiner-Linux
20+ command : --onefile --name KickDropMiner
21+ - os : macos-latest
22+ name : KickDropMiner-macOS
23+ command : --onefile --name KickDropMiner
24+
25+ steps :
26+ - name : Checkout code
27+ uses : actions/checkout@v4
28+
29+ - name : Set up Python
30+ uses : actions/setup-python@v5
31+ with :
32+ python-version : ' 3.12'
33+
34+ - name : Install dependencies
35+ run : |
36+ python -m pip install --upgrade pip
37+ pip install -r requirements.txt
38+ pip install pyinstaller
39+
40+ - name : Build with PyInstaller
41+ run : |
42+ pyinstaller ${{ matrix.command }} `
43+ --add-data "templates:templates" `
44+ --add-data "static:static" `
45+ --add-data "locales:locales" `
46+ webui/app.py
47+
48+ - name : Build with PyInstaller (Linux/macOS fix)
49+ if : runner.os != 'Windows'
50+ run : |
51+ pyinstaller ${{ matrix.command }} \
52+ --add-data "templates:templates" \
53+ --add-data "static:static" \
54+ --add-data "locales:locales" \
55+ webui/app.py
56+
57+ - name : Upload artifact (for debugging)
58+ uses : actions/upload-artifact@v4
59+ with :
60+ name : ${{ matrix.name }}
61+ path : dist/*
62+
63+ - name : Upload to Release
64+ if : startsWith(github.ref, 'refs/tags/v')
65+ uses : softprops/action-gh-release@v2
66+ with :
67+ files : |
68+ dist/KickDropMiner*
69+ fail_on_unmatched_files : true
0 commit comments