fix
This commit is contained in:
@@ -37,9 +37,9 @@ if (localBin) {
|
||||
cmd = localBin;
|
||||
args = [exePath, '--set-icon', iconPath];
|
||||
} else {
|
||||
// Fallback to npx. Note: Node can't execute PowerShell shims (npx.ps1), so this may fail
|
||||
// in environments that only provide .ps1 launchers.
|
||||
cmd = 'npx';
|
||||
// Fallback to npx. Use the platform-specific shim on Windows so Node spawn finds it.
|
||||
// PowerShell-only shims like npx.ps1 won't work with Node spawn; prefer npx.cmd.
|
||||
cmd = process.platform === 'win32' ? 'npx.cmd' : 'npx';
|
||||
args = ['rcedit', exePath, '--set-icon', iconPath];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user