Skip to content

Commit

Permalink
Fix cannot start ComfyUI: File not found
Browse files Browse the repository at this point in the history
- Resolves various issues caused at different installation states, when PowerShell is not in PATH
- Forces standard env for all users - uses Windows PowerShell even if PS core is default
  • Loading branch information
webfiltered committed Jan 3, 2025
1 parent a70edd0 commit a445b34
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/shell/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ import os from 'node:os';
export function getDefaultShell(): string {
switch (os.platform()) {
case 'win32':
return 'powershell.exe';
// Use full path to avoid e.g. https://github.com/Comfy-Org/desktop/issues/584
return `${process.env.SYSTEMROOT}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`;
case 'darwin':
return 'zsh';
default: // Linux and others
Expand Down

0 comments on commit a445b34

Please sign in to comment.