MCPcopy Create free account
hub / github.com/continuedev/continue / getPreferredShell

Function getPreferredShell

core/tools/definitions/runTerminalCommand.ts:13–24  ·  view source on GitHub ↗

* Get the preferred shell for the current platform * @returns The preferred shell command or path

()

Source from the content-addressed store, hash-verified

11 * @returns The preferred shell command or path
12 */
13function getPreferredShell(): string {
14 const platform = os.platform();
15
16 if (platform === "win32") {
17 return "powershell.exe";
18 } else if (platform === "darwin") {
19 return process.env.SHELL || "/bin/zsh";
20 } else {
21 // Linux and other Unix-like systems
22 return process.env.SHELL || "/bin/bash";
23 }
24}
25
26const PLATFORM_INFO = `Choose terminal commands and scripts optimized for ${os.platform()} and ${os.arch()} and shell ${getPreferredShell()}.`;
27

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected