feat(terminal): add configurable default shell#127
Merged
xintaofei merged 1 commit intoxintaofei:mainfrom Apr 29, 2026
Merged
Conversation
ed8e0fb to
1a22de1
Compare
Owner
|
感谢pr |
xintaofei
added a commit
that referenced
this pull request
Apr 29, 2026
- feat(terminal): configurable default shell with backend-driven picker — `get_available_terminal_shells` / `probe_terminal_shell_path` serve the platform-aware option list, install state and `resolve_shell()` fallback; the settings UI renders the response verbatim and supports a custom shell path on every platform. POSIX spawn now distinguishes bash-family shells from unknown shells like nu/xonsh/elvish so the latter spawn cleanly without bash-only `-l -i` / `eval` flags. Localized across all 10 languages. Thanks to @Kwensiu for contributing the initial implementation in #127. - feat(chat): file paths in Read/Write tool call headers and Edit/ApplyPatch diff headers are now clickable and open the file in the workspace panel via the existing local-file confirmation dialog; new-file Write/NotebookEdit bodies render with the same green tint as added diff lines. - feat(chat): cap inline code block height inside messages with internal overflow scroll, so long code dumps no longer push the rest of the conversation off-screen. - fix(dialog): constrain `DialogContent` to viewport height with internal scrolling, and cap the git reset commit message at 8rem with its own scrollbar, so the dialog footer stays visible on long messages or short viewports. ----------------------------- # 发布版本 0.11.1 - 新增(终端):默认 Shell 改由后端驱动选择 —— `get_available_terminal_shells` / `probe_terminal_shell_path` 提供与平台相关的可选项、安装状态及 `resolve_shell()` 兜底逻辑,设置界面按后端返回原样渲染;所有平台均支持自定义 Shell 路径输入。POSIX 层在 spawn 时区分 bash 家族 Shell 与 nu/xonsh/elvish 等非 bash Shell,避免后者因 `-l -i` / `eval` 等 bash 专属参数无法启动;新增字符串已覆盖全部 10 种语言。感谢 @Kwensiu 在 #127 中贡献初版实现。 - 新增(聊天):Read/Write 工具调用头部以及 Edit/ApplyPatch 差异头部中的文件路径现已可点击,复用既有的本地文件确认弹窗在工作区面板中打开;新文件场景下 Write/NotebookEdit 正文使用与新增差异行一致的绿色高亮渲染; - 新增(聊天):消息中的行内代码块高度被限制并启用内部滚动,长代码片段不再把后续对话挤出可视区域; - 修复(对话框):`DialogContent` 限制到视口高度并启用内部滚动,Git 重置提交消息限高 8rem 带独立滚动条,长消息或小视口下底部按钮始终可见。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
变更说明
本次变更新增了持久化的
SystemTerminalSettings,通过 Tauri 命令和 Web API 同步暴露default_shell配置。前端终端上下文会在初始化时加载默认终端配置,并订阅设置更新事件。之后通过以下入口创建的新终端标签页都会自动带上默认 shell:
Ctrl+J首次打开终端面板时自动创建的终端+同时保留了底层终端创建链路对显式
shell参数的支持,但将默认 shell 选择入口统一到“设置 → 系统”。有考虑过使用类似 VSC 的弹窗选择启动 Shell,但是超出本次 PR 范畴没有进行添加
平台行为
Windows 可选项包括:
pwsh.exe)powershell.exe)cmd.exe)macOS / Linux / Server 仅提供系统默认