github / github/copilot-cli

Feature Request: Support user-configurable keybindings via keybindings.json

未關閉
#2,259 0 則留言 6 個 reaction 已指派 0 人 在 GitHub 檢視
area:input-keyboard
主要語言
Shell
星號
11.2k
分支
1.9k
平均合併
14 小時 16 分鐘
30 天內合併 PR
6

描述

### Describe the feature or problem you'd like to solve

All keybindings in Copilot CLI are currently fixed and cannot be customized. This creates friction for users whose terminal/shell already uses some of the default shortcuts, and limits flexibility for different keyboard layouts and personal workflows.

Claude Code (Anthropic's competing CLI) recently shipped a `keybinds.json` config file that lets users remap keyboard shortcuts. Having a similar feature in Copilot CLI would close this gap and give users more control over their UX.

### Proposed solution

Following the existing pattern of user-level config files (e.g. `~/.copilot/lsp-config.json`), add support for a `~/.copilot/keybindings.json` file that allows remapping built-in actions to custom key combinations.

Example:

```json
{
"keybindings": [
{ "action": "clearScreen", "key": "ctrl+l" },
{ "action": "cycleMode", "key": "ctrl+m" },
{ "action": "cancelOperation", "key": "ctrl+c" }
]
}
```

A repo-level override at `.github/keybindings.json` could also be considered, consistent with how instructions files work.

### Example prompts or workflows

- A user whose terminal multiplexer captures `ctrl+k` wants to remap the "delete to end of line" action to a different chord.
- A user on a non-US keyboard layout needs to remap actions that conflict with accented character input.
- A power user wants shortcuts that match their muscle memory from another tool (e.g. VS Code, Emacs, Vim).

### Additional context

Reference: Anthropic added `keybinds.json` support to Claude Code CLI, allowing users to define custom keyboard shortcuts.

貢獻指南

開啟貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。