Browse Source

fix: exit aliases

Adam 2 months ago
parent
commit
862141e8b2
1 changed files with 5 additions and 0 deletions
  1. 5 0
      packages/opencode/src/cli/cmd/tui/component/prompt/index.tsx

+ 5 - 0
packages/opencode/src/cli/cmd/tui/component/prompt/index.tsx

@@ -410,6 +410,11 @@ export function Prompt(props: PromptProps) {
     if (props.disabled) return
     if (autocomplete.visible) return
     if (!store.prompt.input) return
+    const trimmed = store.prompt.input.trim()
+    if (trimmed === "exit" || trimmed === "quit" || trimmed === ":q") {
+      exit()
+      return
+    }
     const selectedModel = local.model.current()
     if (!selectedModel) {
       promptModelWarning()