zed
zed copied to clipboard
Keybinding CMD+K not working
Check for existing issues
- [X] Completed
Describe the bug / provide steps to reproduce it
keymap.json
// Zed keymap
//
// For information on binding keys, see the Zed
// documentation: https://zed.dev/docs/key-bindings
//
// To see the default key bindings run `zed: open default keymap`
// from the command palette.
[
{
"context": "Workspace",
"bindings": {
// "shift shift": "file_finder::Toggle"
}
},
{
"context": "Editor",
"bindings": {
// "j k": ["workspace::SendKeystrokes", "escape"]
"cmd-k n": ["editor::GoToDiagnostic"]
}
}
]
Environment
Zed: v0.149.5 (Zed) OS: macOS 14.5.0 Memory: 32 GiB Architecture: aarch64
If applicable, add mockups / screenshots to help explain present your vision of the feature
No response
If applicable, attach your Zed.log file to this issue.
Zed.log
That keybinding works for me.
Did you perhaps want diagnostics::Deploy (toggles focus to the Diagnostics panel)?
editor::GoToDiagnostic (goes to the next diagnostic error/warning in the current file, pairs with editor::GoToPrevDiagnostic to go to the previous)?
No, I mean the key binding doesn't do anything, regardless of what I make the action. Maybe I'm putting in the wrong syntax for cmd or maybe these are silently failing?
// Zed keymap
//
// For information on binding keys, see the Zed
// documentation: https://zed.dev/docs/key-bindings
//
// To see the default key bindings run `zed: open default keymap`
// from the command palette.
[
{
"context": "Workspace",
"bindings": {
// "shift shift": "file_finder::Toggle"
}
},
{
"context": "Editor",
"bindings": {
// "j k": ["workspace::SendKeystrokes", "escape"]
"cmd-k n": ["editor::GoToDiagnostic"],
"ctrl-cmd-w": ["pane::CloseInactiveItems"],
"cmd-@": ["editor::FindAllReferences"]
}
}
]
// Zed keymap
//
// For information on binding keys, see the Zed
// documentation: https://zed.dev/docs/key-bindings
//
// To see the default key bindings run `zed: open default keymap`
// from the command palette.
[
{
"context": "Workspace",
"bindings": {
// "shift shift": "file_finder::Toggle"
}
},
{
"context": "Editor",
"bindings": {
// "j k": ["workspace::SendKeystrokes", "escape"]
"cmd-k n": "editor::GoToDiagnostic",
"ctrl-cmd-w": "pane::CloseInactiveItems",
"cmd-@": "editor::FindAllReferences"
}
}
]
Use this and it will work. I've tested all 3 bindings for Editor and they all work.