Repository navigation
feat(macos): add Command-arrow terminal line navigation - #1086
Open
Life-go-on wants to merge 1 commit into
Open
Life-go-on wants to merge 1 commit into
Life-go-on wants to merge 1 commit into
Conversation
Co-Authored-By: Claude Code <noreply@anthropic.com>
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.
Advertising, commercial promotion, and traffic solicitation are prohibited in PRs
and Issues. Business requests must go through the email in the
contribution policy.
PRs or Issues containing unauthorized promotion will be closed directly.
严禁利用 PR 或 Issue 推广、引流,未经授权的推广将直接关闭;商业需求请通过贡献指南中的邮箱沟通,已获批准的赞助按批准范围处理。
Result / 用户结果
在 macOS 的 Pebrel 终端中,添加按
⌘←可以跳到行首,按⌘→可以跳到行尾的键盘映射,保证与 macOS 文本输入习惯一致。原有 Control 快捷键和普通方向键的行为不变。Design / 设计边界
pebrel_app/src/gpui_shell/terminal/keymap.rs。⌘←和⌘→分别映射为Ctrl+A和Ctrl+E,再复用当前终端窗格已有的键盘协议编码逻辑。不修改设置、搜索等普通输入框,也不改变现有接口。⌘←和⌘→。其他按键组合及非 macOS 平台行为不变,无需迁移配置。Evidence / 验证依据
cargo test --locked --release -p pebrel --bin pebrel gpui_shell::terminal::keymap::tests:在 macOS Apple Silicon 上运行,27 项通过。python3 scripts/check_architecture.py --base 76f74be1、git diff --check和改动文件的格式检查均通过。⌘←和⌘→编码为普通方向键,无法跳到行首或行尾。新增测试覆盖两个方向在传统和增强键盘协议下的编码,并验证叠加其他修饰键时仍沿用原有行为。Required Review / 必须确认
CONTRIBUTING.md,docs/architecture.md, anddocs/project-constraints.md.python3 scripts/check_architecture.py --base <PR-base-commit>passes; budgets were not inflated to fit the change.Checkboxes explain the review; they do not replace CI or maintainer approval.