Skip to content

Instantly share code, notes, and snippets.

@rosswintle
Created February 13, 2018 14:18
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rosswintle/30f198a64bd0c606c28c5f160229088f to your computer and use it in GitHub Desktop.
Save rosswintle/30f198a64bd0c606c28c5f160229088f to your computer and use it in GitHub Desktop.
Better terminal toggling keybindings in VS Code
[
// Focus/unfocus terminal with ctrl+` and toggle it with ctrl+shift+`
{
"key": "ctrl+`",
"command": "workbench.action.focusActiveEditorGroup",
"when": "terminalFocus"
},
{
"key": "ctrl+`",
"command": "workbench.action.terminal.focus",
"when": "!terminalFocus"
},
{
"key": "ctrl+shift+`",
"command": "workbench.action.terminal.toggleTerminal",
},
]
@rosswintle
Copy link
Author

rosswintle commented Feb 13, 2018

Note - VS Code doesn't seem to mind comments in the keybindings JSON even though they're not officially allowed by the JSON spec.

@rosswintle
Copy link
Author

rosswintle commented Feb 13, 2018

Kudos to @Tyriar who helped out in this issue: microsoft/vscode#12054

@nake89
Copy link

nake89 commented Mar 20, 2019

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment