Is it possible to have multiple actions assigned to one keyboard shortcut in visual studio code?
For example: Move cursor up x 3 set to "ctrl + w"
Thanks in advance.
Is it possible to have multiple actions assigned to one keyboard shortcut in visual studio code?
For example: Move cursor up x 3 set to "ctrl + w"
Thanks in advance.
Multiple actions is not supported natively. But for now you can use extention macros.
settings.json
(ctrl+,) >>
"macros": {
"cursorUp3x": [
"cursorUp",
"cursorUp",
"cursorUp"
]
},
keybindings.json
(ctrl+k, ctrl+s) keybindings.json link click >>
{
"key": "ctrl+w",
"command": "macros.cursorUp3x"
}
Feature-request: Macro like keybindings #871
For anyone else looking for an answer, learn to make your own VS code extensions. It took about an hour and I was able to make all sorts of shortcuts that executed multiple commands. The vs code site has good resources for it: https://code.visualstudio.com/docs/extensions/overview