Last active
May 16, 2023 09:23
-
-
Save cognominal/00bc297fa6093cb2ebbe4754e6541019 to your computer and use it in GitHub Desktop.
vscode mac keybindings
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
// Mac specific ? | |
// I try to keep many of my keybindings in the alt+* format | |
// Some are alternate of existing more complex keybindings. | |
// to optimize the keybinding space, the same keybindings will be used for different commands | |
// on different contexts. I keep them alphabetized | |
// I don't want to clobber emacs bindings with the alt-* bindings | |
// except when they have alternative using the arrow keys. | |
[ | |
{ | |
"key": "alt+a", | |
"command": "keybindings.editor.addKeybinding", | |
"when": "inKeybindings && keybindingFocus" | |
}, | |
{ | |
"key": "alt+a", | |
"command": "workbench.action.toggleActivityBarVisibility" | |
}, | |
{ | |
"key": "alt+b", | |
"command": "workbench.action.tasks.build", | |
"when": "taskCommandsRegistered && readOnly" | |
}, | |
{ | |
"key": "alt+c", | |
"command": "workbench.action.closePanel" | |
}, | |
{ | |
"key": "alt+e", | |
"command": "workbench.view.explorer" | |
}, | |
{ | |
"key": "alt+g", | |
"command": "workbench.view.scm", | |
"when": "workbench.scm.active" | |
}, | |
{ | |
"key": "alt+k", | |
"command": "keybindings.editor.recordSearchKeys", | |
"when": "inKeybindings" | |
}, | |
{ | |
"key": "alt+k", | |
"command": "workbench.action.openGlobalKeybindings", | |
"when": "!inKeybindings" | |
}, | |
{ | |
"key": "alt+l", | |
"command": "expandLineSelection", | |
"when": "textInputFocus" | |
}, | |
{ | |
"key": "alt+m", | |
"command": "markdown.showPreview", | |
"when": "!notebookEditorFocused && editorLangId == 'markdown'" | |
}, | |
// { | |
// "key": "alt+f", | |
// "command": "workbench.action.findInFiles" | |
// }, | |
{ | |
"key": "alt+r", | |
"command": "workbench.action.openRecent" | |
}, | |
{ | |
"key": "alt+p", | |
"command": "workbench.action.showCommands" | |
}, | |
{ | |
"key": "alt+s", | |
"command": "toggleSearchRegex", | |
"when": "searchViewletFocus" | |
}, | |
{ | |
"key": "alt+s", | |
"command": "toggleFindRegex", | |
"when": "editorFocus" | |
}, | |
{ | |
"key": "alt+s", | |
"command": "editor.action.smartSelect.expand", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+t", | |
"command": "copilotSidebar.generateTests.focus" | |
}, | |
{ | |
"key": "alt+w", | |
"command": "workbench.action.switchWindow" | |
}, | |
{ | |
"key": "alt+x", | |
"command": "workbench.view.extensions", | |
"when": "viewContainer.workbench.view.extensions.enabled" | |
}, | |
{ | |
"key": "alt+z", | |
"command": "editor.action.rename", | |
"when": "editorHasRenameProvider && editorTextFocus && !editorReadonly" | |
}, | |
{ | |
"key": "shift+alt+r", | |
"command": "workbench.view.remote" | |
}, | |
{ | |
"key": "ctrl+x ctrl+q", | |
"command": "reader-mode.toggle" | |
}, | |
{ | |
"key": "ctrl+[ ctrl+s", | |
"command": "-editor.action.nextMatchFindAction", | |
"when": "config.emacs-mcx.useMetaPrefixCtrlLeftBracket && findInputFocussed" | |
}, | |
{ | |
"key": "down", | |
"command": "-emacs-mcx.isearchExit", | |
"when": "editorFocus && findWidgetVisible && !config.emacs-mcx.cursorMoveOnFindWidget && !isComposing && !replaceInputFocussed" | |
}, | |
{ | |
"key": "down", | |
"command": "-emacs-mcx.nextLine", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "down", | |
"command": "-emacs-mcx.nextLine", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "up", | |
"command": "-emacs-mcx.isearchExit", | |
"when": "editorFocus && findWidgetVisible && !config.emacs-mcx.cursorMoveOnFindWidget && !isComposing && !replaceInputFocussed" | |
}, | |
{ | |
"key": "right", | |
"command": "-emacs-mcx.isearchExit", | |
"when": "editorFocus && findWidgetVisible && !config.emacs-mcx.cursorMoveOnFindWidget && !isComposing && !replaceInputFocussed" | |
}, | |
{ | |
"key": "left", | |
"command": "-emacs-mcx.isearchExit", | |
"when": "editorFocus && findWidgetVisible && !config.emacs-mcx.cursorMoveOnFindWidget && !isComposing && !replaceInputFocussed" | |
}, | |
{ | |
"key": "ctrl+r", | |
"command": "emacs-mcx.isearchBackwardRegexp", | |
"when": "config.emacs-mcx.useMetaPrefixCtrlLeftBracket && !findInputFocussed" | |
}, | |
{ | |
"key": "ctrl+[ ctrl+r", | |
"command": "-emacs-mcx.isearchBackwardRegexp", | |
"when": "config.emacs-mcx.useMetaPrefixCtrlLeftBracket && !findInputFocussed" | |
}, | |
{ | |
"key": "ctrl+shift+right", | |
"command": "-editor.action.smartSelect.expand", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "shift+cmd+[", | |
"command": "-emacs-mcx.backwardParagraph", | |
"when": "config.emacs-mcx.useMetaPrefixMacCmd && editorTextFocus && !suggestWidgetVisible" | |
}, | |
{ | |
"key": "f2", | |
"command": "-editor.action.rename", | |
"when": "editorHasRenameProvider && editorTextFocus && !editorReadonly" | |
}, | |
{ | |
"key": "ctrl+x ctrl+q", | |
"command": "workbench.action.files.toggleActiveEditorReadonlyInSession" | |
}, | |
{ | |
"key": "alt+f", | |
"command": "footsteps.toggleHighlightingLines" | |
}, | |
{ | |
"key": "alt+f", | |
"command": "-emacs-mcx.forwardWord", | |
"when": "editorTextFocus && !config.emacs-mcx.useMetaPrefixMacCmd" | |
}, | |
{ | |
"key": "alt+b", | |
"command": "editor.action.jumpToBracket", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "shift+cmd+\\", | |
"command": "-editor.action.jumpToBracket", | |
"when": "editorTextFocus" | |
}, | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment