()
| 96 | } |
| 97 | |
| 98 | function win() { |
| 99 | return Array.from( |
| 100 | new Set( |
| 101 | [which("pwsh"), which("powershell"), gitbash(), process.env.COMSPEC || "cmd.exe"] |
| 102 | .filter((item): item is string => Boolean(item)) |
| 103 | .map(full), |
| 104 | ), |
| 105 | ) |
| 106 | } |
| 107 | |
| 108 | async function unix() { |
| 109 | const text = await readFile("/etc/shells", "utf8").catch(() => "") |