Skip to content

Instantly share code, notes, and snippets.

@wonkwh
Forked from brennanMKE/README.md
Created November 17, 2023 04:36
Show Gist options
  • Save wonkwh/49ef1ed704677f23c9d5473a32d2afee to your computer and use it in GitHub Desktop.
Save wonkwh/49ef1ed704677f23c9d5473a32d2afee to your computer and use it in GitHub Desktop.
Key bindings for VS Code to work more like Xcode

The workbench in VS Code on the left has 5 buttons so cmd+1 through cmd+5 will select them.

Running the debugger is started with cmd+r and stopping the debugging is done with cmd+. just like Xcode.

[
{
"key": "cmd+1",
"command": "workbench.view.explorer"
},
{
"key": "cmd+2",
"command": "workbench.view.search"
},
{
"key": "cmd+3",
"command": "workbench.view.scm"
},
{
"key": "cmd+4",
"command": "workbench.view.debug"
},
{
"key": "cmd+5",
"command": "workbench.view.extensions"
},
{
"key": "cmd+b",
"command": "workbench.action.tasks.build"
},
{
"key": "cmd+r",
"command": "workbench.action.debug.start",
"when": "!inDebugMode"
},
{
"key": "cmd+r",
"command": "workbench.action.debug.restart",
"when": "inDebugMode"
},
{
"key": "cmd+e",
"command": "workbench.action.tasks.runTask"
},
{
"key": "cmd+.",
"command": "workbench.action.debug.stop",
"when": "inDebugMode"
},
{
"key": "cmd+0",
"command": "workbench.action.toggleSidebarVisibility"
},
{
"key": "cmd+-",
"command": "workbench.action.navigateBack"
},
{
"key": "cmd+=",
"command": "workbench.action.navigateForward"
},
{
"key": "cmd+shift+r",
"command": "workbench.action.tasks.runTask"
},
{
"key": "cmd+alt+left",
"command": "editor.foldRecursively"
},
{
"key": "cmd+alt+right",
"command": "editor.unfoldRecursively"
}
]
@wonkwh
Copy link
Author

wonkwh commented Nov 17, 2023

{
    "key": "cmd+shift+y",
    "command": "workbench.action.togglePanel"
},

@wonkwh
Copy link
Author

wonkwh commented Nov 17, 2023

{
    "key": "cmd+ctrl+left",
    "command": "workbench.action.navigateBack"
},
{
    "key": "cmd+ctrl+right",
    "command": "workbench.action.navigateForward"
},

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