docs: add NSIS shortcut icons section to CI/CD guide
Explains how to use custom .ico files for shortcuts instead of the default Python/WSH icon that appears in the taskbar.
This commit is contained in:
@@ -472,6 +472,23 @@ Section "Start with Windows" SecAutostart ; Optional — Startup folder shortcut
|
||||
; But NOT $INSTDIR\data (user config)
|
||||
```
|
||||
|
||||
### Shortcut Icons
|
||||
|
||||
By default, shortcuts that launch via `wscript.exe` or `python.exe` inherit the Python/Windows Script Host icon in the taskbar. To use a custom icon, set the 4th parameter of `CreateShortcut` to your `.ico` file:
|
||||
|
||||
```nsi
|
||||
; Set installer/uninstaller icons (shown during install wizard)
|
||||
!define MUI_ICON "src\static\icons\icon.ico"
|
||||
!define MUI_UNICON "src\static\icons\icon.ico"
|
||||
|
||||
; Shortcut with custom icon (4th param = icon path, 5th = icon index)
|
||||
CreateShortcut "$DESKTOP\${APPNAME}.lnk" \
|
||||
"wscript.exe" '"$INSTDIR\scripts\start-hidden.vbs"' \
|
||||
"$INSTDIR\app\static\icons\icon.ico" 0
|
||||
```
|
||||
|
||||
The `.ico` file must be bundled in the distribution (copied by the build script). The same icon path applies to Start Menu, Desktop, and Startup shortcuts.
|
||||
|
||||
### Hidden Launcher (VBS)
|
||||
|
||||
Bat files briefly flash a console window even with `@echo off`. To avoid this,
|
||||
|
||||
Reference in New Issue
Block a user