Skip to content

Instantly share code, notes, and snippets.

@bagustris
Created May 7, 2026 01:54
Show Gist options
  • Select an option

  • Save bagustris/e9f297e38a11e9c8cb268dcd1a70d5f5 to your computer and use it in GitHub Desktop.

Select an option

Save bagustris/e9f297e38a11e9c8cb268dcd1a70d5f5 to your computer and use it in GitHub Desktop.
Keyboard shortcut for my VSCode
// Place your key bindings in this file to override the defaults
[
// {
// "key": "cmd+shift+h",
// "command": "workbench.action.terminal.newWithCwd",
// "args": {
// "cwd": "${fileDirname}"
// }},
{
"key": "alt+t",
"command": "workbench.action.terminal.sendSequence",
"args": {"text": "cd '${fileDirname}'\u000D"}
},
{
"key": "tab",
"command": "selectNextSuggestion",
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
},
{
"key": "shift+tab",
"command": "selectPrevSuggestion",
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
},
// Toggle between terminal and editor focus
{ "key": "ctrl+`", "command": "workbench.action.terminal.focus"},
{ "key": "ctrl+`", "command": "workbench.action.focusActiveEditorGroup", "when": "terminalFocus"},
{
"key": "ctrl+alt+n",
"command": "python.execInTerminal"
},
{
"key": "ctrl+tab",
"command": "workbench.action.terminal.focusNext",
"when": "terminalFocus"
},
{
"key": "shift+tab",
"command": "workbench.action.nextEditorInGroup",
"when": "editorFocus"
},
{
"key": "shift+enter",
"command": "-jupyter.execSelectionInteractive",
"when": "editorTextFocus && jupyter.ownsSelection && !findInputFocussed && !notebookEditorFocused && !replaceInputFocussed && editorLangId == 'python'"
},
{
"key": "shift+enter",
"command": "-jupyter.runcurrentcelladvance",
"when": "editorTextFocus && jupyter.hascodecells && !editorHasSelection && !notebookEditorFocused"
},
{
"key": "shift+enter",
"command": "-notebook.cell.executeAndSelectBelow",
"when": "notebookCellListFocused && notebookCellType == 'markdown' || notebookCellListFocused && notebookCellExecutionState == 'failed' || notebookCellExecutionState == 'idle' || notebookCellExecutionState == 'succeeded' && notebookKernelCount > 0"
},
{
"key": "shift+enter",
"command": "-python.execSelectionInTerminal",
"when": "editorTextFocus && !findInputFocussed && !jupyter.ownsSelection && !notebookEditorFocused && !replaceInputFocussed && editorLangId == 'python'"
},
{
"key": "shift+enter",
"command": "workbench.action.terminal.runSelectedText"
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment