Skip to content

Commit e5b18f6

Browse files
Update build-exe.yml
1 parent 0309375 commit e5b18f6

1 file changed

Lines changed: 16 additions & 10 deletions

File tree

.github/workflows/build-exe.yml

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -30,23 +30,27 @@ jobs:
3030
with:
3131
nuitka-version: main
3232

33-
# --- CORRECTED FLAGS AND INPUTS BELOW ---
33+
# --- CORRECTED AND OPTIMIZED CONFIGURATION ---
3434

35-
# Nuitka command-line arguments are passed directly with the script name.
36-
# We add --onefile to create a single executable.
35+
# 1. EXPLICITLY SET THE C COMPILER
36+
# This is the most critical fix. It ensures Nuitka finds and uses the MSVC compiler.
37+
msvc-version: 'latest'
38+
39+
# 2. ENABLE PLUGINS
40+
# Instrument control apps often use Qt and NumPy. These plugins are essential
41+
# for Nuitka to find all necessary files and hidden imports.
42+
enable-plugins: "qt-binding,numpy"
43+
44+
# Pass Nuitka command-line arguments directly with the script name.
3745
script-name: PICA_Launcher_V4.py --onefile
3846

3947
# 'disable-console' is the correct input for the action to hide the command window.
4048
disable-console: true
41-
42-
# Specify the output directory to keep the project root clean.
43-
output-dir: build
44-
49+
4550
# This is a valid action input. Ensure the path is correct from the repo root.
4651
windows-icon-from-ico: _assets/LOGO/UGC_DAE_CSR.ico
4752

4853
# For including data directories, the format is source=destination.
49-
# This copies the entire folder into the build at the specified destination path.
5054
include-data-dir: |
5155
_assets=_assets
5256
Delta_mode=Delta_mode
@@ -62,8 +66,10 @@ jobs:
6266
uses: svenstaro/upload-release-action@v2
6367
with:
6468
repo_token: ${{ secrets.GITHUB_TOKEN }}
65-
# The file path now correctly points to the output directory we specified.
66-
file: build/PICA_Launcher_V4.exe
69+
# Nuitka automatically puts the onefile executable in a '.dist' folder
70+
# e.g., PICA_Launcher_V4.dist/PICA_Launcher_V4.exe
71+
file: PICA_Launcher_V4.dist/PICA_Launcher_V4.exe
6772
asset_name: PICA_Launcher-Windows-${{ github.ref_name }}.exe
6873
tag: ${{ github.ref }}
6974
overwrite: true
75+

0 commit comments

Comments
 (0)