Feature Request: Support user-configurable keybindings via keybindings.json
- Langage dominant
- Shell
- Étoiles
- 11.2k
- Forks
- 1.9k
- Merge moyen
- 14 h 16 min
- PR mergées (30 j)
- 6
Description
### 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.
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Commencez par lire le modèle de configuration existant au niveau utilisateur dans ~/.copilot/lsp-config.json. Définissez comment ~/.copilot/keybindings.json associe des actions telles que clearScreen, cycleMode et cancelOperation à des combinaisons de touches, et examinez la surcharge proposée par .github/keybindings.json. C’est terminé lorsque les utilisateurs peuvent réaffecter les actions intégrées de CLI via le format de configuration documenté.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- shell
- Domaine
- cli, developer-experience
- Type d'issue
- Fonctionnalité
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Activité
- Calme
- Clarté
- Plutôt claire
- Accessibilité débutants
- 38/100