From 18ac67372e2d5f241d89cdbb49da192b475809b2 Mon Sep 17 00:00:00 2001 From: "gcp-cherry-pick-bot[bot]" <98988430+gcp-cherry-pick-bot[bot]@users.noreply.github.com> Date: Mon, 21 Apr 2025 14:15:16 -0600 Subject: [PATCH] Fix ctrl-c in vim normal mode (cherry-pick #29167) (#29169) Cherry-picked Fix ctrl-c in vim normal mode (#29167) This was broken when we added helix keybindings because we populate the menu's shortcut based on the "last" seen binding for an action ignoring context. Release Notes: - Fix `ctrl-c` in vim normal mode Co-authored-by: Conrad Irwin --- assets/keymaps/vim.json | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/assets/keymaps/vim.json b/assets/keymaps/vim.json index 452731ebc2b6603b0c2f9abae19e0dfa98190497..248469028250e98e49b15a58010be66743fa3bbf 100644 --- a/assets/keymaps/vim.json +++ b/assets/keymaps/vim.json @@ -830,5 +830,13 @@ // and Windows. "alt-l": "editor::AcceptEditPrediction" } + }, + { + // Fixes https://github.com/zed-industries/zed/issues/29095 by ensuring that + // the last binding for editor::ToggleComments is not ctrl-c. + "context": "hack_to_fix_ctrl-c", + "bindings": { + "g c": "editor::ToggleComments" + } } ]