diff --git a/packages/app/src/components/settings-general.tsx b/packages/app/src/components/settings-general.tsx index d9f82129f9..c45a31cf3f 100644 --- a/packages/app/src/components/settings-general.tsx +++ b/packages/app/src/components/settings-general.tsx @@ -48,6 +48,8 @@ type ShellOption = { acceptable: boolean } +const AUTO_SHELL_VALUE = "__opencode_auto_shell__" + // To prevent audio from overlapping/playing very quickly when navigating the settings menus, // delay the playback by 100ms during quick selection changes and pause existing sounds. const stopDemoSound = () => { @@ -179,7 +181,8 @@ export const SettingsGeneral: Component = () => { const globalSdk = useGlobalSDK() const [shells] = createResource(() => globalSdk.client.pty.shells().then((res) => res.data || [])) - const auto = { value: "", label: "Auto (Default)" } + const auto = { value: AUTO_SHELL_VALUE, label: "Auto (Default)" } + const currentShell = createMemo(() => globalSync.data.config.shell || AUTO_SHELL_VALUE) const shellOptions = createMemo(() => { const list = shells() || [] @@ -293,12 +296,12 @@ export const SettingsGeneral: Component = () => {