mirror of
https://github.com/js0ny/dotfiles.git
synced 2025-12-21 08:43:00 +00:00
This commit is contained in:
parent
041a509481
commit
d210461abe
9 changed files with 3346 additions and 1058 deletions
|
|
@ -3,7 +3,8 @@
|
|||
// Load settings from: https://raw.githubusercontent.com/js0ny/dotfiles/refs/heads/master/tools/browser/surfingkeys.js
|
||||
// Browse to Extension > Surfingkeys > Allow access to file URLs to enable local file access
|
||||
// Windows: file:///C:/Users/username/.dotfiles/tools/browser/surfingkeys.js
|
||||
// *nix: file:///home/username/.dotfiles/tools/browser/surfingkeys.js
|
||||
// Linux: file:///home/username/.dotfiles/tools/browser/surfingkeys.js
|
||||
// macOS: file:///Users/username/.dotfiles/tools/browser/surfingkeys.js
|
||||
|
||||
// #region Example
|
||||
/** Examples
|
||||
|
|
|
|||
726
tools/vscode/keybindings-macos.jsonc
Normal file
726
tools/vscode/keybindings-macos.jsonc
Normal file
|
|
@ -0,0 +1,726 @@
|
|||
// Place your key bindings in this file to override the defaults
|
||||
[
|
||||
// #region mac minor change for cross-platform compatiblity
|
||||
{
|
||||
"key": "cmd+r",
|
||||
"command": "workbench.action.openRecent"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+r",
|
||||
"command": "-workbench.action.openRecent"
|
||||
},
|
||||
{
|
||||
"key": "cmd+k cmd+o",
|
||||
"command": "workbench.action.files.openFileFolder",
|
||||
"when": "isMacNative && openFolderWorkspaceSupport"
|
||||
},
|
||||
// #endregion
|
||||
// #region quickOpen (Telescope)
|
||||
{
|
||||
"key": "cmd+p",
|
||||
"command": "workbench.action.quickOpen"
|
||||
},
|
||||
{
|
||||
"key": "cmd+p",
|
||||
"command": "workbench.action.quickOpenNavigatePrevious",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "cmd+n",
|
||||
"command": "workbench.action.quickOpenNavigateNext",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "cmd+[",
|
||||
"command": "workbench.action.closeQuickOpen",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+[",
|
||||
"command": "workbench.action.closeQuickOpen",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{ // Emacs-like
|
||||
"key": "ctrl+g",
|
||||
"command": "workbench.action.closeQuickOpen",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{ // Emacs-like: M-x to show command palette
|
||||
"key": "alt+x",
|
||||
"command": "workbench.action.showCommands"
|
||||
},
|
||||
// #endregion
|
||||
// #region Extension: Code Runner
|
||||
{
|
||||
"key": "ctrl+alt+n",
|
||||
"command": "-code-runner.run"
|
||||
},
|
||||
// #endregion
|
||||
// #region Nvim-Tree like File Explorer
|
||||
// n, e : move cursor up/down
|
||||
// h : move cursor to parent folder
|
||||
// i : open file or folder
|
||||
{
|
||||
"key": "e",
|
||||
"command": "list.focusUp",
|
||||
"when": "notebookEditorFocused && !inputFocus && !notebookOutputInputFocused"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-list.focusUp",
|
||||
"when": "notebookEditorFocused && !inputFocus && !notebookOutputInputFocused"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "list.focusUp",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-list.focusUp",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "f",
|
||||
"command": "filesExplorer.findInWorkspace",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "n",
|
||||
"command": "list.focusDown",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "j",
|
||||
"command": "-list.focusDown",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "list.select",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "l",
|
||||
"command": "-list.select",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{ // z: Close all folders
|
||||
"key": "z",
|
||||
"command": "workbench.files.action.collapseExplorerFolders",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // <leader>e: Close left sidebar if is in file explorer
|
||||
"key": "space e",
|
||||
"command": "workbench.action.toggleSidebarVisibility",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && filesExplorerFocus"
|
||||
},
|
||||
{ // <leader>e: Focus on file explorer if is on sidebar and not in file explorer
|
||||
"key": "space e",
|
||||
"command": "workbench.files.action.focusFilesExplorer",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && !filesExplorerFocus"
|
||||
},
|
||||
{ // <leader>g: Focus on file explorer if is on sidebar and not in file explorer
|
||||
"key": "space g",
|
||||
"command": "workbench.scm.focus",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && !scmViewletVisible"
|
||||
},
|
||||
{ // a: add
|
||||
"key": "a",
|
||||
"command": "explorer.newFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // p: paste
|
||||
"key": "p",
|
||||
"command": "filesExplorer.paste",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // x: cut
|
||||
"key": "x",
|
||||
"command": "filesExplorer.cut",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // d: delete
|
||||
"key": "d",
|
||||
"command": "deleteFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // r: rename
|
||||
"key": "r",
|
||||
"command": "renameFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // s: open in vertical split / to side
|
||||
"key": "s",
|
||||
"command": "explorer.openToSide",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // A: add folder
|
||||
"key": "shift+a",
|
||||
"command": "explorer.newFolder",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // C: Copy path
|
||||
"key": "shift+c",
|
||||
"command": "copyFilePath",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // E: Open in File Explorer
|
||||
"key": "shift+e",
|
||||
"command": "revealFileInOS",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // E: Open in File Explorer (WSL)
|
||||
"key": "shift+e",
|
||||
"command": "remote-wsl.revealInExplorer",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus && remoteName == 'wsl'"
|
||||
},
|
||||
{ // O: Open with System App
|
||||
"key": "shift+o",
|
||||
"command": "openInExternalApp.open",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // Y: Copy Relative Path
|
||||
"key": "shift+y",
|
||||
"command": "copyRelativeFilePath",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // R: Copy Relative Path
|
||||
"key": "shift+r",
|
||||
"command": "workbench.files.action.refreshFilesExplorer",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // T: Open in terminal
|
||||
"key": "shift+t",
|
||||
"command": "openInIntegratedTerminal",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Vim-like Hover Browsing
|
||||
{
|
||||
"key": "h",
|
||||
"command": "editor.action.scrollLeftHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "n",
|
||||
"command": "editor.action.scrollDownHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "editor.action.scrollUpHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "editor.action.scrollRightHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
// #endregion
|
||||
// #region Comment and semicolons
|
||||
{
|
||||
"key": "cmd+;",
|
||||
"command": "extension.insertSemicolon",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "cmd+/",
|
||||
"command": "-extension.insertSemicolon",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Vim-like Jupyter Navigation
|
||||
{
|
||||
"key": "n",
|
||||
"command": "notebook.focusNextEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'none' && notebookEditorCursorAtBoundary != 'top'"
|
||||
},
|
||||
{
|
||||
"key": "j",
|
||||
"command": "-notebook.focusNextEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'none' && notebookEditorCursorAtBoundary != 'top'"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "notebook.focusPreviousEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'bottom' && notebookEditorCursorAtBoundary != 'none'"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-notebook.focusPreviousEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'bottom' && notebookEditorCursorAtBoundary != 'none'"
|
||||
},
|
||||
// #endregion
|
||||
// #region Editor: Completions
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "workbench.action.files.newUntitledFile",
|
||||
"when": "!suggestWidgetVisible && !inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "-workbench.action.files.newUntitledFile"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "selectNextSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus || suggestWidgetVisible && textInputFocus && !suggestWidgetHasFocusedSuggestion"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "selectPrevSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus || suggestWidgetVisible && textInputFocus && !suggestWidgetHasFocusedSuggestion"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "acceptSelectedSuggestion",
|
||||
"when": "suggestWidgetVisible && textInputFocus && !inlineSuggestionVisible"
|
||||
},
|
||||
{
|
||||
"key": "alt+f",
|
||||
"command": "editor.action.inlineSuggest.commit",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "editor.action.inlineSuggest.acceptNextWord",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "hideSuggestWidget",
|
||||
"when": "suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "editor.action.inlineSuggest.hide",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Terminal: tmux-like terminal control
|
||||
{
|
||||
"key": "cmd+0",
|
||||
"command": "workbench.action.focusLastEditorGroup",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + x : kill terminal
|
||||
"key": "ctrl+a x",
|
||||
"command": "workbench.action.terminal.kill",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + c : create new terminal
|
||||
"key": "ctrl+a c",
|
||||
"command": "workbench.action.terminal.new",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + | : split terminal vertically
|
||||
"key": "ctrl+a shift+\\",
|
||||
"command": "workbench.action.terminal.split",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + \ : split terminal vertically
|
||||
"key": "ctrl+a \\",
|
||||
"command": "workbench.action.terminal.split",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + / : search
|
||||
"key": "ctrl+a /",
|
||||
"command": "workbench.action.terminal.focusFind",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + t : toggle terminal
|
||||
"key": "ctrl+a t",
|
||||
"command": "workbench.action.terminal.toggleTerminal",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + ^a: show information
|
||||
"key": "ctrl+a ctrl+a",
|
||||
"command": "workbench.action.terminal.focusHover",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+i",
|
||||
"command": "-workbench.action.terminal.focusHover",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 1 : focus terminal 1
|
||||
"key": "ctrl+a 1",
|
||||
"command": "workbench.action.terminal.focusAtIndex1",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 2 : focus terminal 2
|
||||
"key": "ctrl+a 2",
|
||||
"command": "workbench.action.terminal.focusAtIndex2",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 3 : focus terminal 3
|
||||
"key": "ctrl+a 3",
|
||||
"command": "workbench.action.terminal.focusAtIndex3",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + g : Go to recent directory
|
||||
"key": "ctrl+a g",
|
||||
"command": "workbench.action.terminal.goToRecentDirectory",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+g",
|
||||
"command": "-workbench.action.terminal.goToRecentDirectory",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{ // prefix + d : detach terminal
|
||||
"key": "ctrl+a d",
|
||||
"command": "workbench.action.terminal.detachSession",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{ // prefix + a : attach to session
|
||||
"key": "ctrl+a a",
|
||||
"command": "workbench.action.terminal.attachToSession",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a h",
|
||||
"command": "workbench.action.terminal.focusPreviousPane",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a i",
|
||||
"command": "workbench.action.terminal.focusNextPane",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+H",
|
||||
"command": "workbench.action.terminal.resizePaneLeft",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+N",
|
||||
"command": "workbench.action.terminal.resizePaneDown",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+E",
|
||||
"command": "workbench.action.terminal.resizePaneUp",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+I",
|
||||
"command": "workbench.action.terminal.resizePaneRight",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "cmd+`",
|
||||
"command": "workbench.action.terminal.toggleTerminal",
|
||||
"when": "terminal.active"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+`",
|
||||
"command": "-workbench.action.terminal.toggleTerminal",
|
||||
"when": "terminal.active"
|
||||
},
|
||||
// {
|
||||
// "key": "space",
|
||||
// "command": "vspacecode.space",
|
||||
// "when": "activeEditorGroupEmpty && focusedView == '' && !whichkeyActive && !inputFocus"
|
||||
// },
|
||||
// {
|
||||
// "key": "space",
|
||||
// "command": "vspacecode.space",
|
||||
// "when": "sideBarFocus && !inputFocus && !whichkeyActive"
|
||||
// },
|
||||
{
|
||||
"key": "tab",
|
||||
"command": "extension.vim_tab",
|
||||
"when": "editorTextFocus && vim.active && !inDebugRepl && vim.mode != 'Insert' && editorLangId != 'magit'"
|
||||
},
|
||||
{
|
||||
"key": "tab",
|
||||
"command": "-extension.vim_tab",
|
||||
"when": "editorTextFocus && vim.active && !inDebugRepl && vim.mode != 'Insert'"
|
||||
},
|
||||
{
|
||||
"key": "x",
|
||||
"command": "magit.discard-at-point",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-magit.discard-at-point"
|
||||
},
|
||||
{
|
||||
"key": "-",
|
||||
"command": "magit.reverse-at-point",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "v",
|
||||
"command": "-magit.reverse-at-point"
|
||||
},
|
||||
{
|
||||
"key": "shift+-",
|
||||
"command": "magit.reverting",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "shift+v",
|
||||
"command": "-magit.reverting"
|
||||
},
|
||||
{
|
||||
"key": "shift+o",
|
||||
"command": "magit.resetting",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "shift+x",
|
||||
"command": "-magit.resetting"
|
||||
},
|
||||
{
|
||||
"key": "x",
|
||||
"command": "-magit.reset-mixed"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+u x",
|
||||
"command": "-magit.reset-hard"
|
||||
},
|
||||
{
|
||||
"key": "y",
|
||||
"command": "-magit.show-refs"
|
||||
},
|
||||
{
|
||||
"key": "y",
|
||||
"command": "vspacecode.showMagitRefMenu",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode == 'Normal'"
|
||||
},
|
||||
{
|
||||
"key": "g",
|
||||
"command": "-magit.refresh",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "g",
|
||||
"command": "vspacecode.showMagitRefreshMenu",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "workbench.action.quickOpenSelectNext",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "workbench.action.quickOpenSelectPrevious",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "selectNextSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "selectPrevSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "acceptSelectedSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "showNextParameterHint",
|
||||
"when": "editorFocus && parameterHintsMultipleSignatures && parameterHintsVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "showPrevParameterHint",
|
||||
"when": "editorFocus && parameterHintsMultipleSignatures && parameterHintsVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "selectNextCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "selectPrevCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "acceptSelectedCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+h",
|
||||
"command": "file-browser.stepOut",
|
||||
"when": "inFileBrowser"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "file-browser.stepIn",
|
||||
"when": "inFileBrowser"
|
||||
},
|
||||
{
|
||||
"key": "space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "activeEditorGroupEmpty && focusedView == '' && !whichkeyActive && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "sideBarFocus && !inputFocus && !whichkeyActive"
|
||||
},
|
||||
// #endregion
|
||||
// #region Editor: multicursor
|
||||
{
|
||||
"key": "alt+e",
|
||||
"command": "editor.action.insertCursorAbove",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+up",
|
||||
"command": "-editor.action.insertCursorAbove",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+n",
|
||||
"command": "editor.action.insertCursorBelow",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+down",
|
||||
"command": "-editor.action.insertCursorBelow",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Emacs like Cursor Movements
|
||||
{ // macOS original C-a will move to BoL, VSCode cursorHome will move to BoL & first non-whitespace character
|
||||
"key": "ctrl+a",
|
||||
"command": "cursorHome",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
// no C-A and C-k C-a to select all, use S-a instead
|
||||
{
|
||||
"key": "ctrl+e",
|
||||
"command": "cursorEnd",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+b",
|
||||
"command": "cursorWordStartLeft",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+f",
|
||||
"command": "cursorWordStartRight",
|
||||
"when": "textInputFocus && !inlineEditIsVisible && !suggestWidgetVisible && !inlineSuggestionVisible"
|
||||
},
|
||||
// #endregion
|
||||
// #region Ctrl+W Remaps (Vim-like)
|
||||
{
|
||||
"key": "ctrl+w h",
|
||||
"command": "workbench.action.navigateLeft"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+h",
|
||||
"command": "workbench.action.toggleSidebarVisibility"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w i",
|
||||
"command": "workbench.action.navigateRight"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+i",
|
||||
"command": "workbench.action.toggleAuxiliaryBar"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w n",
|
||||
"command": "workbench.action.navigateDown"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+n",
|
||||
"command": "workbench.action.togglePanel"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w e",
|
||||
"command": "workbench.action.navigateUp"
|
||||
},
|
||||
{ // original ^w
|
||||
"key": "ctrl+w ctrl+w",
|
||||
"command": "workbench.action.closeActiveEditor",
|
||||
"when": "editorFocus || inSettingsEditor || inKeybindings || inWelcome"
|
||||
},
|
||||
{ // :only
|
||||
"key": "ctrl+w o",
|
||||
"command": "runCommands",
|
||||
"args": {
|
||||
"commands": [
|
||||
"workbench.action.joinAllGroups",
|
||||
"workbench.action.maximizeEditorHideSidebar"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+w",
|
||||
"command": "workbench.action.closeGroup",
|
||||
"when": "activeEditorGroupEmpty && multipleEditorGroups"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w",
|
||||
"command": "-workbench.action.closeGroup",
|
||||
"when": "activeEditorGroupEmpty && multipleEditorGroups"
|
||||
},
|
||||
// #endregion
|
||||
// #region Extension: VSpaceCode
|
||||
{
|
||||
"key": "alt+q",
|
||||
"command": "vspacecode.space"
|
||||
},
|
||||
// #endregion
|
||||
// #region Sidebar: Search View
|
||||
{ // Focus on search list, therefore can use n/e to move up/down
|
||||
"key": "escape",
|
||||
"command": "search.action.focusSearchList",
|
||||
"when": "searchViewletFocus && inputBoxFocus"
|
||||
},
|
||||
{ // Focus on main input box
|
||||
"key": "l",
|
||||
"command": "workbench.action.replaceInFiles",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "r",
|
||||
"command": "toggleSearchRegex",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "w",
|
||||
"command": "toggleSearchWholeWord",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "c",
|
||||
"command": "toggleSearchCaseSensitive",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "p",
|
||||
"command": "toggleSearchPreserveCase",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "search.action.focusFilesToInclude",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "shift+e",
|
||||
"command": "search.action.focusFilesToExclude",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Miscs and todos
|
||||
// #endregion
|
||||
]
|
||||
834
tools/vscode/keybindings-windows-linux.jsonc
Normal file
834
tools/vscode/keybindings-windows-linux.jsonc
Normal file
|
|
@ -0,0 +1,834 @@
|
|||
// Place your key bindings in this file to override the defaultsauto[]
|
||||
[
|
||||
// #region quickOpen (Telescope)
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "workbench.action.quickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "workbench.action.quickOpenNavigatePrevious",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "workbench.action.quickOpenNavigateNext",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+[",
|
||||
"command": "workbench.action.closeQuickOpen",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{ // Emacs-like
|
||||
"key": "ctrl+g",
|
||||
"command": "workbench.action.closeQuickOpen",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{ // Emacs-like: M-x to show command palette
|
||||
"key": "alt+x",
|
||||
"command": "workbench.action.showCommands"
|
||||
},
|
||||
// #endregion
|
||||
// #region Extension: Code Runner
|
||||
{
|
||||
"key": "ctrl+alt+n",
|
||||
"command": "-code-runner.run"
|
||||
},
|
||||
// #endregion
|
||||
// #region Comment and semicolons
|
||||
{
|
||||
"key": "ctrl+oem_1", // ctrl+;
|
||||
"command": "extension.insertSemicolon",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{ // change to toggle comment
|
||||
"key": "ctrl+oem_2", // ctrl+/;
|
||||
"command": "-extension.insertSemicolon",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+oem_1",
|
||||
"command": "extension.insertSemicolonWithNewLine",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+oem_2",
|
||||
"command": "-extension.insertSemicolonWithNewLine",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+oem_2",
|
||||
"command": "github.copilot.acceptCursorPanelSolution",
|
||||
"when": "github.copilot.activated && github.copilot.panelVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+oem_2",
|
||||
"command": "-github.copilot.acceptCursorPanelSolution",
|
||||
"when": "github.copilot.activated && github.copilot.panelVisible"
|
||||
},
|
||||
// #endregion
|
||||
// #region Nvim-Tree like File Explorer
|
||||
// n, e : move cursor up/down
|
||||
// h : move cursor to parent folder
|
||||
// i : open file or folder
|
||||
{
|
||||
"key": "e",
|
||||
"command": "list.focusUp",
|
||||
"when": "notebookEditorFocused && !inputFocus && !notebookOutputInputFocused"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-list.focusUp",
|
||||
"when": "notebookEditorFocused && !inputFocus && !notebookOutputInputFocused"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "list.focusUp",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-list.focusUp",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "f",
|
||||
"command": "filesExplorer.findInWorkspace",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "n",
|
||||
"command": "list.focusDown",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "j",
|
||||
"command": "-list.focusDown",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "list.select",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "l",
|
||||
"command": "-list.select",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{ // z: Close all folders
|
||||
"key": "z",
|
||||
"command": "workbench.files.action.collapseExplorerFolders",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // <leader>e: Close left sidebar if is in file explorer
|
||||
"key": "space e",
|
||||
"command": "workbench.action.toggleSidebarVisibility",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && filesExplorerFocus"
|
||||
},
|
||||
{ // <leader>e: Focus on file explorer if is on sidebar and not in file explorer
|
||||
"key": "space e",
|
||||
"command": "workbench.files.action.focusFilesExplorer",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && !filesExplorerFocus"
|
||||
},
|
||||
{ // <leader>g: Focus on file explorer if is on sidebar and not in file explorer
|
||||
"key": "space g",
|
||||
"command": "workbench.scm.focus",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && !scmViewletVisible"
|
||||
},
|
||||
{ // a: add
|
||||
"key": "a",
|
||||
"command": "explorer.newFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // p: paste
|
||||
"key": "p",
|
||||
"command": "filesExplorer.paste",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // x: cut
|
||||
"key": "x",
|
||||
"command": "filesExplorer.cut",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // d: delete
|
||||
"key": "d",
|
||||
"command": "deleteFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // r: rename
|
||||
"key": "r",
|
||||
"command": "renameFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // s: open in vertical split / to side
|
||||
"key": "s",
|
||||
"command": "explorer.openToSide",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // A: add folder
|
||||
"key": "shift+a",
|
||||
"command": "explorer.newFolder",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // C: Copy path
|
||||
"key": "shift+c",
|
||||
"command": "copyFilePath",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // E: Open in File Explorer
|
||||
"key": "shift+e",
|
||||
"command": "revealFileInOS",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // E: Open in File Explorer (WSL)
|
||||
"key": "shift+e",
|
||||
"command": "remote-wsl.revealInExplorer",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus && remoteName == 'wsl'"
|
||||
},
|
||||
{ // O: Open with System App
|
||||
"key": "shift+o",
|
||||
"command": "openInExternalApp.open",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // Y: Copy Relative Path
|
||||
"key": "shift+y",
|
||||
"command": "copyRelativeFilePath",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // R: Copy Relative Path
|
||||
"key": "shift+r",
|
||||
"command": "workbench.files.action.refreshFilesExplorer",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // T: Open in terminal
|
||||
"key": "shift+t",
|
||||
"command": "openInIntegratedTerminal",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Vim-like Hover Browsing
|
||||
{
|
||||
"key": "h",
|
||||
"command": "editor.action.scrollLeftHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "n",
|
||||
"command": "editor.action.scrollDownHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "editor.action.scrollUpHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "editor.action.scrollRightHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
// #endregion
|
||||
// #region Vim-like Jupyter Navigation
|
||||
{
|
||||
"key": "n",
|
||||
"command": "notebook.focusNextEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'none' && notebookEditorCursorAtBoundary != 'top'"
|
||||
},
|
||||
{
|
||||
"key": "j",
|
||||
"command": "-notebook.focusNextEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'none' && notebookEditorCursorAtBoundary != 'top'"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "notebook.focusPreviousEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'bottom' && notebookEditorCursorAtBoundary != 'none'"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-notebook.focusPreviousEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'bottom' && notebookEditorCursorAtBoundary != 'none'"
|
||||
},
|
||||
// #endregion
|
||||
// #region Git / Source Control
|
||||
// { // Alt+Enter: Send Commit when editing commit message
|
||||
// "key": "alt+enter",
|
||||
// "command": "git.commitMessageAccept",
|
||||
// "when": "editorLangId=\"git-commit\""
|
||||
// },
|
||||
{
|
||||
"key": "ctrl+shift+g c",
|
||||
"command": "-gitlens.showQuickCommitFileDetails",
|
||||
"when": "editorTextFocus && !gitlens:disabled && config.gitlens.keymap == 'chorded'"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+g s",
|
||||
"command": "git.stageAll"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+g g",
|
||||
"command": "workbench.view.scm",
|
||||
"when": "workbench.scm.active"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+g",
|
||||
"command": "-workbench.view.scm",
|
||||
"when": "workbench.scm.active"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+shift+b",
|
||||
"command": "editor.action.goToSelectionAnchor"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+shift+i",
|
||||
"command": "workbench.action.selectProductIconTheme"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l p",
|
||||
"command": "-extension.openPrGitProvider"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l g",
|
||||
"command": "-extension.openInGitHub"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l c",
|
||||
"command": "-extension.copyGitHubLinkToClipboard"
|
||||
},
|
||||
// #endregion
|
||||
// #region Use ^pbnf to navigate completions
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "workbench.action.files.newUntitledFile",
|
||||
"when": "!suggestWidgetVisible && !inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "-workbench.action.files.newUntitledFile"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "selectNextSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus || suggestWidgetVisible && textInputFocus && !suggestWidgetHasFocusedSuggestion"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "selectPrevSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus || suggestWidgetVisible && textInputFocus && !suggestWidgetHasFocusedSuggestion"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "acceptSelectedSuggestion",
|
||||
"when": "suggestWidgetVisible && textInputFocus && !inlineSuggestionVisible"
|
||||
},
|
||||
{
|
||||
"key": "alt+f",
|
||||
"command": "editor.action.inlineSuggest.commit",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "editor.action.inlineSuggest.acceptNextWord",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "hideSuggestWidget",
|
||||
"when": "suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "editor.action.inlineSuggest.hide",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Terminal Control, use ^a as prefix / leader key
|
||||
// tmux-like terminal control
|
||||
{ // prefix + x : kill terminal
|
||||
"key": "ctrl+a space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + x : kill terminal
|
||||
"key": "ctrl+a x",
|
||||
"command": "workbench.action.terminal.kill",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + c : create new terminal
|
||||
"key": "ctrl+a c",
|
||||
"command": "workbench.action.terminal.new",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + | : split terminal vertically
|
||||
"key": "ctrl+a shift+\\",
|
||||
"command": "workbench.action.terminal.split",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + \ : split terminal vertically
|
||||
"key": "ctrl+a \\",
|
||||
"command": "workbench.action.terminal.split",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + / : search
|
||||
"key": "ctrl+a /",
|
||||
"command": "workbench.action.terminal.focusFind",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + t : toggle terminal
|
||||
"key": "ctrl+a t",
|
||||
"command": "workbench.action.terminal.toggleTerminal",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + ^a: show information
|
||||
"key": "ctrl+a ctrl+a",
|
||||
"command": "workbench.action.terminal.focusHover",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+i",
|
||||
"command": "-workbench.action.terminal.focusHover",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 1 : focus terminal 1
|
||||
"key": "ctrl+a 1",
|
||||
"command": "workbench.action.terminal.focusAtIndex1",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 2 : focus terminal 2
|
||||
"key": "ctrl+a 2",
|
||||
"command": "workbench.action.terminal.focusAtIndex2",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 3 : focus terminal 3
|
||||
"key": "ctrl+a 3",
|
||||
"command": "workbench.action.terminal.focusAtIndex3",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + g : Go to recent directory
|
||||
"key": "ctrl+a g",
|
||||
"command": "workbench.action.terminal.goToRecentDirectory",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+g",
|
||||
"command": "-workbench.action.terminal.goToRecentDirectory",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{ // prefix + d : detach terminal
|
||||
"key": "ctrl+a d",
|
||||
"command": "workbench.action.terminal.detachSession",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{ // prefix + a : attach to session
|
||||
"key": "ctrl+a a",
|
||||
"command": "workbench.action.terminal.attachToSession",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a h",
|
||||
"command": "workbench.action.terminal.focusPreviousPane",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a i",
|
||||
"command": "workbench.action.terminal.focusNextPane",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+H",
|
||||
"command": "workbench.action.terminal.resizePaneLeft",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+N",
|
||||
"command": "workbench.action.terminal.resizePaneDown",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+E",
|
||||
"command": "workbench.action.terminal.resizePaneUp",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+I",
|
||||
"command": "workbench.action.terminal.resizePaneRight",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
// #endregion
|
||||
// #region Misc
|
||||
{
|
||||
"key": "ctrl+o",
|
||||
"command": "-workbench.action.files.openFolderViaWorkspace",
|
||||
"when": "!openFolderWorkspaceSupport && workbenchState == 'workspace'"
|
||||
},
|
||||
{
|
||||
"key": "f9",
|
||||
"command": "csdevkit.debug.noDebugFileLaunch"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+h",
|
||||
"command": "-editor.action.startFindReplaceAction",
|
||||
"when": "editorFocus || editorIsOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+h",
|
||||
"command": "-extension.vim_ctrl+h",
|
||||
"when": "editorTextFocus && vim.active && vim.use<C-h> && !inDebugRepl"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+r",
|
||||
"command": "-workbench.action.reloadWindow",
|
||||
"when": "isDevelopment"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+r",
|
||||
"command": "-workbench.action.terminal.runRecentCommand",
|
||||
"when": "terminalFocus && terminalHasBeenCreated && !accessibilityModeEnabled || terminalFocus && terminalProcessSupported && !accessibilityModeEnabled"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+r",
|
||||
"command": "-workbench.action.terminal.runRecentCommand",
|
||||
"when": "accessibilityModeEnabled && terminalFocus && terminalHasBeenCreated || accessibilityModeEnabled && terminalFocus && terminalProcessSupported || accessibilityModeEnabled && accessibleViewIsShown && terminalHasBeenCreated && accessibleViewCurrentProviderId == 'terminal' || accessibilityModeEnabled && accessibleViewIsShown && terminalProcessSupported && accessibleViewCurrentProviderId == 'terminal'"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+r",
|
||||
"command": "-rerunSearchEditorSearch",
|
||||
"when": "inSearchEditor"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+r",
|
||||
"command": "-editor.action.refactor",
|
||||
"when": "editorHasCodeActionsProvider && textInputFocus && !editorReadonly"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+r",
|
||||
"command": "workbench.action.quickOpenNavigatePreviousInRecentFilesPicker",
|
||||
"when": "inQuickOpen && inRecentFilesPicker"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+l",
|
||||
"command": "cursorLineStart",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "activeEditorGroupEmpty && focusedView == '' && !whichkeyActive && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "sideBarFocus && !inputFocus && !whichkeyActive"
|
||||
},
|
||||
{
|
||||
"key": "tab",
|
||||
"command": "extension.vim_tab",
|
||||
"when": "editorTextFocus && vim.active && !inDebugRepl && vim.mode != 'Insert' && editorLangId != 'magit'"
|
||||
},
|
||||
{
|
||||
"key": "tab",
|
||||
"command": "-extension.vim_tab",
|
||||
"when": "editorTextFocus && vim.active && !inDebugRepl && vim.mode != 'Insert'"
|
||||
},
|
||||
{
|
||||
"key": "x",
|
||||
"command": "magit.discard-at-point",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-magit.discard-at-point"
|
||||
},
|
||||
{
|
||||
"key": "-",
|
||||
"command": "magit.reverse-at-point",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "v",
|
||||
"command": "-magit.reverse-at-point"
|
||||
},
|
||||
{
|
||||
"key": "shift+-",
|
||||
"command": "magit.reverting",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "shift+v",
|
||||
"command": "-magit.reverting"
|
||||
},
|
||||
{
|
||||
"key": "shift+o",
|
||||
"command": "magit.resetting",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "shift+x",
|
||||
"command": "-magit.resetting"
|
||||
},
|
||||
{
|
||||
"key": "x",
|
||||
"command": "-magit.reset-mixed"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+u x",
|
||||
"command": "-magit.reset-hard"
|
||||
},
|
||||
{
|
||||
"key": "y",
|
||||
"command": "-magit.show-refs"
|
||||
},
|
||||
{
|
||||
"key": "y",
|
||||
"command": "vspacecode.showMagitRefMenu",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode == 'Normal'"
|
||||
},
|
||||
{
|
||||
"key": "g",
|
||||
"command": "-magit.refresh",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "g",
|
||||
"command": "vspacecode.showMagitRefreshMenu",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "workbench.action.quickOpenSelectNext",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "workbench.action.quickOpenSelectPrevious",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "selectNextSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "selectPrevSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "acceptSelectedSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "showNextParameterHint",
|
||||
"when": "editorFocus && parameterHintsMultipleSignatures && parameterHintsVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "showPrevParameterHint",
|
||||
"when": "editorFocus && parameterHintsMultipleSignatures && parameterHintsVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "selectNextCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "selectPrevCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "acceptSelectedCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+h",
|
||||
"command": "file-browser.stepOut",
|
||||
"when": "inFileBrowser"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "file-browser.stepIn",
|
||||
"when": "inFileBrowser"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+oem_4",
|
||||
"command": "whichkey.undoKey",
|
||||
"when": "whichkeyVisible"
|
||||
},
|
||||
// #region multicursor
|
||||
{
|
||||
"key": "alt+e",
|
||||
"command": "editor.action.insertCursorAbove",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+up",
|
||||
"command": "-editor.action.insertCursorAbove",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+n",
|
||||
"command": "editor.action.insertCursorBelow",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+down",
|
||||
"command": "-editor.action.insertCursorBelow",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #endregion
|
||||
// #region Ctrl+W Remaps (Vim-like)
|
||||
{
|
||||
"key": "ctrl+w h",
|
||||
"command": "workbench.action.navigateLeft"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+h",
|
||||
"command": "workbench.action.toggleSidebarVisibility"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w i",
|
||||
"command": "workbench.action.navigateRight"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+i",
|
||||
"command": "workbench.action.toggleAuxiliaryBar"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w n",
|
||||
"command": "workbench.action.navigateDown"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+n",
|
||||
"command": "workbench.action.togglePanel"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w e",
|
||||
"command": "workbench.action.navigateUp"
|
||||
},
|
||||
{ // original ^w
|
||||
"key": "ctrl+w ctrl+w",
|
||||
"command": "workbench.action.closeActiveEditor",
|
||||
"when": "editorFocus || inSettingsEditor || inKeybindings || inWelcome"
|
||||
},
|
||||
{ // :only
|
||||
"key": "ctrl+w o",
|
||||
"command": "runCommands",
|
||||
"args": {
|
||||
"commands": [
|
||||
"workbench.action.joinAllGroups",
|
||||
"workbench.action.maximizeEditorHideSidebar"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+w",
|
||||
"command": "workbench.action.closeGroup",
|
||||
"when": "activeEditorGroupEmpty && multipleEditorGroups"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w",
|
||||
"command": "-workbench.action.closeGroup",
|
||||
"when": "activeEditorGroupEmpty && multipleEditorGroups"
|
||||
},
|
||||
// #endregion
|
||||
// #region Emacs like Cursor Movement
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "cursorRight",
|
||||
"when": "textInputFocus && !inlineEditIsVisible && !suggestWidgetVisible && !inlineSuggestionVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "cursorLeft",
|
||||
"when": "textInputFocus && !inlineEditIsVisible && !suggestWidgetVisible && !inlineSuggestionVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "cursorDown",
|
||||
"when": "textInputFocus && !suggestWidgetVisible && !inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "cursorUp",
|
||||
"when": "textInputFocus && !suggestWidgetVisible && !inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a",
|
||||
"command": "cursorHome",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+a",
|
||||
"command": "cursorEnd",
|
||||
"when": "editor.action.selectAll"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+a",
|
||||
"command": "editor.action.selectAll"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+e",
|
||||
"command": "cursorEnd",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+b",
|
||||
"command": "cursorWordStartLeft",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+f",
|
||||
"command": "cursorWordStartRight",
|
||||
"when": "textInputFocus && !inlineEditIsVisible && !suggestWidgetVisible && !inlineSuggestionVisible"
|
||||
},
|
||||
// #endregion
|
||||
// #region Search View
|
||||
{ // Focus on search list, therefore can use n/e to move up/down
|
||||
"key": "escape",
|
||||
"command": "search.action.focusSearchList",
|
||||
"when": "searchViewletFocus && inputBoxFocus"
|
||||
},
|
||||
{ // Focus on main input box
|
||||
"key": "l",
|
||||
"command": "workbench.action.replaceInFiles",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "r",
|
||||
"command": "toggleSearchRegex",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "w",
|
||||
"command": "toggleSearchWholeWord",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "c",
|
||||
"command": "toggleSearchCaseSensitive",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "p",
|
||||
"command": "toggleSearchPreserveCase",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "search.action.focusFilesToInclude",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "shift+e",
|
||||
"command": "search.action.focusFilesToExclude",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
// #endregion
|
||||
]
|
||||
|
|
@ -1,850 +0,0 @@
|
|||
// Place your key bindings in this file to override the defaultsauto[]
|
||||
[
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "workbench.action.quickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "workbench.action.quickOpenNavigatePrevious",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "workbench.action.quickOpenNavigateNext",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+[",
|
||||
"command": "workbench.action.closeQuickOpen",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{ // Emacs-like
|
||||
"key": "ctrl+g",
|
||||
"command": "workbench.action.closeQuickOpen",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{ // Emacs-like: M-x to show command palette
|
||||
"key": "alt+x",
|
||||
"command": "workbench.action.showCommands"
|
||||
},
|
||||
// #endregion
|
||||
// #region Extension: Code Runner
|
||||
{
|
||||
"key": "ctrl+alt+n",
|
||||
"command": "-code-runner.run"
|
||||
},
|
||||
// #endregion
|
||||
// #region Comment and semicolons
|
||||
{
|
||||
"key": "ctrl+oem_1", // ctrl+;
|
||||
"command": "extension.insertSemicolon",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{ // change to toggle comment
|
||||
"key": "ctrl+oem_2", // ctrl+/;
|
||||
"command": "-extension.insertSemicolon",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+oem_1",
|
||||
"command": "extension.insertSemicolonWithNewLine",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+oem_2",
|
||||
"command": "-extension.insertSemicolonWithNewLine",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+oem_2",
|
||||
"command": "github.copilot.acceptCursorPanelSolution",
|
||||
"when": "github.copilot.activated && github.copilot.panelVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+oem_2",
|
||||
"command": "-github.copilot.acceptCursorPanelSolution",
|
||||
"when": "github.copilot.activated && github.copilot.panelVisible"
|
||||
},
|
||||
// #endregion
|
||||
// #region Nvim-Tree like File Explorer
|
||||
// n, e : move cursor up/down
|
||||
// h : move cursor to parent folder
|
||||
// i : open file or folder
|
||||
{
|
||||
"key": "e",
|
||||
"command": "list.focusUp",
|
||||
"when": "notebookEditorFocused && !inputFocus && !notebookOutputInputFocused"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-list.focusUp",
|
||||
"when": "notebookEditorFocused && !inputFocus && !notebookOutputInputFocused"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "list.focusUp",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-list.focusUp",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "f",
|
||||
"command": "filesExplorer.findInWorkspace",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "n",
|
||||
"command": "list.focusDown",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "j",
|
||||
"command": "-list.focusDown",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "list.select",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "l",
|
||||
"command": "-list.select",
|
||||
"when": "listFocus && !inputFocus"
|
||||
},
|
||||
{ // z: Close all folders
|
||||
"key": "z",
|
||||
"command": "workbench.files.action.collapseExplorerFolders",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // <leader>e: Close left sidebar if is in file explorer
|
||||
"key": "space e",
|
||||
"command": "workbench.action.toggleSidebarVisibility",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && filesExplorerFocus"
|
||||
},
|
||||
{ // <leader>e: Focus on file explorer if is on sidebar and not in file explorer
|
||||
"key": "space e",
|
||||
"command": "workbench.files.action.focusFilesExplorer",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && !filesExplorerFocus"
|
||||
},
|
||||
{ // <leader>g: Focus on file explorer if is on sidebar and not in file explorer
|
||||
"key": "space g",
|
||||
"command": "workbench.scm.focus",
|
||||
"when": "sideBarFocus && !inputFocus && !searchViewletVisible && !scmViewletVisible"
|
||||
},
|
||||
{ // a: add
|
||||
"key": "a",
|
||||
"command": "explorer.newFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // p: paste
|
||||
"key": "p",
|
||||
"command": "filesExplorer.paste",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // x: cut
|
||||
"key": "x",
|
||||
"command": "filesExplorer.cut",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // d: delete
|
||||
"key": "d",
|
||||
"command": "deleteFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // r: rename
|
||||
"key": "r",
|
||||
"command": "renameFile",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // s: open in vertical split / to side
|
||||
"key": "s",
|
||||
"command": "explorer.openToSide",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // A: add folder
|
||||
"key": "shift+a",
|
||||
"command": "explorer.newFolder",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // C: Copy path
|
||||
"key": "shift+c",
|
||||
"command": "copyFilePath",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // E: Open in File Explorer
|
||||
"key": "shift+e",
|
||||
"command": "revealFileInOS",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // E: Open in File Explorer (WSL)
|
||||
"key": "shift+e",
|
||||
"command": "remote-wsl.revealInExplorer",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus && remoteName == 'wsl'"
|
||||
},
|
||||
{ // O: Open with System App
|
||||
"key": "shift+o",
|
||||
"command": "openInExternalApp.open",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // Y: Copy Relative Path
|
||||
"key": "shift+y",
|
||||
"command": "copyRelativeFilePath",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // R: Copy Relative Path
|
||||
"key": "shift+r",
|
||||
"command": "workbench.files.action.refreshFilesExplorer",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
{ // T: Open in terminal
|
||||
"key": "shift+t",
|
||||
"command": "openInIntegratedTerminal",
|
||||
"when": "filesExplorerFocus && foldersViewVisible && !explorerResourceIsRoot && !explorerResourceReadonly && !inputFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Vim-like Hover Browsing
|
||||
{
|
||||
"key": "h",
|
||||
"command": "editor.action.scrollLeftHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "n",
|
||||
"command": "editor.action.scrollDownHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "editor.action.scrollUpHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "editor.action.scrollRightHover",
|
||||
"when": "editorHoverFocused"
|
||||
},
|
||||
// #endregion
|
||||
// #region Vim-like Jupyter Navigation
|
||||
{
|
||||
"key": "n",
|
||||
"command": "notebook.focusNextEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'none' && notebookEditorCursorAtBoundary != 'top'"
|
||||
},
|
||||
{
|
||||
"key": "j",
|
||||
"command": "-notebook.focusNextEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'none' && notebookEditorCursorAtBoundary != 'top'"
|
||||
},
|
||||
{
|
||||
"key": "e",
|
||||
"command": "notebook.focusPreviousEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'bottom' && notebookEditorCursorAtBoundary != 'none'"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-notebook.focusPreviousEditor",
|
||||
"when": "editorTextFocus && inputFocus && notebookEditorFocused && vim.mode == 'Normal' && notebookEditorCursorAtBoundary != 'bottom' && notebookEditorCursorAtBoundary != 'none'"
|
||||
},
|
||||
// #endregion
|
||||
// #region Git / Source Control
|
||||
// { // Alt+Enter: Send Commit when editing commit message
|
||||
// "key": "alt+enter",
|
||||
// "command": "git.commitMessageAccept",
|
||||
// "when": "editorLangId=\"git-commit\""
|
||||
// },
|
||||
{
|
||||
"key": "ctrl+shift+g c",
|
||||
"command": "-gitlens.showQuickCommitFileDetails",
|
||||
"when": "editorTextFocus && !gitlens:disabled && config.gitlens.keymap == 'chorded'"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+g s",
|
||||
"command": "git.stageAll"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+g g",
|
||||
"command": "workbench.view.scm",
|
||||
"when": "workbench.scm.active"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+g",
|
||||
"command": "-workbench.view.scm",
|
||||
"when": "workbench.scm.active"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+shift+b",
|
||||
"command": "editor.action.goToSelectionAnchor"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+shift+i",
|
||||
"command": "workbench.action.selectProductIconTheme"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l p",
|
||||
"command": "-extension.openPrGitProvider"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l g",
|
||||
"command": "-extension.openInGitHub"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l c",
|
||||
"command": "-extension.copyGitHubLinkToClipboard"
|
||||
},
|
||||
// #endregion
|
||||
// #region Use ^pbnf to navigate completions
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "workbench.action.files.newUntitledFile",
|
||||
"when": "!suggestWidgetVisible && !inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "-workbench.action.files.newUntitledFile"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "selectNextSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus || suggestWidgetVisible && textInputFocus && !suggestWidgetHasFocusedSuggestion"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "selectPrevSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus || suggestWidgetVisible && textInputFocus && !suggestWidgetHasFocusedSuggestion"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "acceptSelectedSuggestion",
|
||||
"when": "suggestWidgetVisible && textInputFocus && !inlineSuggestionVisible"
|
||||
},
|
||||
{
|
||||
"key": "alt+f",
|
||||
"command": "editor.action.inlineSuggest.commit",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "editor.action.inlineSuggest.acceptNextWord",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "hideSuggestWidget",
|
||||
"when": "suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "editor.action.inlineSuggest.hide",
|
||||
"when": "inlineSuggestionVisible && textInputFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Terminal Control, use ^a as prefix / leader key
|
||||
// tmux-like terminal control
|
||||
{ // prefix + x : kill terminal
|
||||
"key": "ctrl+a space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + x : kill terminal
|
||||
"key": "ctrl+a x",
|
||||
"command": "workbench.action.terminal.kill",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + c : create new terminal
|
||||
"key": "ctrl+a c",
|
||||
"command": "workbench.action.terminal.new",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + | : split terminal vertically
|
||||
"key": "ctrl+a shift+\\",
|
||||
"command": "workbench.action.terminal.split",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + \ : split terminal vertically
|
||||
"key": "ctrl+a \\",
|
||||
"command": "workbench.action.terminal.split",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + / : search
|
||||
"key": "ctrl+a /",
|
||||
"command": "workbench.action.terminal.focusFind",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + t : toggle terminal
|
||||
"key": "ctrl+a t",
|
||||
"command": "workbench.action.terminal.toggleTerminal",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{ // prefix + ^a: show information
|
||||
"key": "ctrl+a ctrl+a",
|
||||
"command": "workbench.action.terminal.focusHover",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+i",
|
||||
"command": "-workbench.action.terminal.focusHover",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 1 : focus terminal 1
|
||||
"key": "ctrl+a 1",
|
||||
"command": "workbench.action.terminal.focusAtIndex1",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 2 : focus terminal 2
|
||||
"key": "ctrl+a 2",
|
||||
"command": "workbench.action.terminal.focusAtIndex2",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + 3 : focus terminal 3
|
||||
"key": "ctrl+a 3",
|
||||
"command": "workbench.action.terminal.focusAtIndex3",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalIsOpen || terminalFocus && terminalProcessSupported || terminalHasBeenCreated && terminalTabsFocus || terminalIsOpen && terminalTabsFocus || terminalProcessSupported && terminalTabsFocus"
|
||||
},
|
||||
{ // prefix + g : Go to recent directory
|
||||
"key": "ctrl+a g",
|
||||
"command": "workbench.action.terminal.goToRecentDirectory",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+g",
|
||||
"command": "-workbench.action.terminal.goToRecentDirectory",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{ // prefix + d : detach terminal
|
||||
"key": "ctrl+a d",
|
||||
"command": "workbench.action.terminal.detachSession",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{ // prefix + a : attach to session
|
||||
"key": "ctrl+a a",
|
||||
"command": "workbench.action.terminal.attachToSession",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a h",
|
||||
"command": "workbench.action.terminal.focusPreviousPane",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a i",
|
||||
"command": "workbench.action.terminal.focusNextPane",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+H",
|
||||
"command": "workbench.action.terminal.resizePaneLeft",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+N",
|
||||
"command": "workbench.action.terminal.resizePaneDown",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+E",
|
||||
"command": "workbench.action.terminal.resizePaneUp",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a shift+I",
|
||||
"command": "workbench.action.terminal.resizePaneRight",
|
||||
"when": "terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported"
|
||||
},
|
||||
// #endregion
|
||||
// #region Misc
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "workbench.action.files.openFileFolder",
|
||||
"when": "isMacNative && openFolderWorkspaceSupport"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+o",
|
||||
"command": "-workbench.action.files.openFileFolder",
|
||||
"when": "isMacNative && openFolderWorkspaceSupport"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "-extension.vim_ctrl+p",
|
||||
"when": "editorTextFocus && vim.active && vim.use<C-p> && !inDebugRepl || vim.active && vim.use<C-p> && !inDebugRepl && vim.mode == 'CommandlineInProgress' || vim.active && vim.use<C-p> && !inDebugRepl && vim.mode == 'SearchInProgressMode'"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+o",
|
||||
"command": "-workbench.action.files.openFolderViaWorkspace",
|
||||
"when": "!openFolderWorkspaceSupport && workbenchState == 'workspace'"
|
||||
},
|
||||
{
|
||||
"key": "f9",
|
||||
"command": "csdevkit.debug.noDebugFileLaunch"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+h",
|
||||
"command": "-editor.action.startFindReplaceAction",
|
||||
"when": "editorFocus || editorIsOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+h",
|
||||
"command": "-extension.vim_ctrl+h",
|
||||
"when": "editorTextFocus && vim.active && vim.use<C-h> && !inDebugRepl"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+r",
|
||||
"command": "-workbench.action.reloadWindow",
|
||||
"when": "isDevelopment"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+r",
|
||||
"command": "-workbench.action.terminal.runRecentCommand",
|
||||
"when": "terminalFocus && terminalHasBeenCreated && !accessibilityModeEnabled || terminalFocus && terminalProcessSupported && !accessibilityModeEnabled"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+r",
|
||||
"command": "-workbench.action.terminal.runRecentCommand",
|
||||
"when": "accessibilityModeEnabled && terminalFocus && terminalHasBeenCreated || accessibilityModeEnabled && terminalFocus && terminalProcessSupported || accessibilityModeEnabled && accessibleViewIsShown && terminalHasBeenCreated && accessibleViewCurrentProviderId == 'terminal' || accessibilityModeEnabled && accessibleViewIsShown && terminalProcessSupported && accessibleViewCurrentProviderId == 'terminal'"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+r",
|
||||
"command": "-rerunSearchEditorSearch",
|
||||
"when": "inSearchEditor"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+r",
|
||||
"command": "-editor.action.refactor",
|
||||
"when": "editorHasCodeActionsProvider && textInputFocus && !editorReadonly"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+r",
|
||||
"command": "workbench.action.quickOpenNavigatePreviousInRecentFilesPicker",
|
||||
"when": "inQuickOpen && inRecentFilesPicker"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+l",
|
||||
"command": "cursorLineStart",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "activeEditorGroupEmpty && focusedView == '' && !whichkeyActive && !inputFocus"
|
||||
},
|
||||
{
|
||||
"key": "space",
|
||||
"command": "vspacecode.space",
|
||||
"when": "sideBarFocus && !inputFocus && !whichkeyActive"
|
||||
},
|
||||
{
|
||||
"key": "tab",
|
||||
"command": "extension.vim_tab",
|
||||
"when": "editorTextFocus && vim.active && !inDebugRepl && vim.mode != 'Insert' && editorLangId != 'magit'"
|
||||
},
|
||||
{
|
||||
"key": "tab",
|
||||
"command": "-extension.vim_tab",
|
||||
"when": "editorTextFocus && vim.active && !inDebugRepl && vim.mode != 'Insert'"
|
||||
},
|
||||
{
|
||||
"key": "x",
|
||||
"command": "magit.discard-at-point",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "k",
|
||||
"command": "-magit.discard-at-point"
|
||||
},
|
||||
{
|
||||
"key": "-",
|
||||
"command": "magit.reverse-at-point",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "v",
|
||||
"command": "-magit.reverse-at-point"
|
||||
},
|
||||
{
|
||||
"key": "shift+-",
|
||||
"command": "magit.reverting",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "shift+v",
|
||||
"command": "-magit.reverting"
|
||||
},
|
||||
{
|
||||
"key": "shift+o",
|
||||
"command": "magit.resetting",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "shift+x",
|
||||
"command": "-magit.resetting"
|
||||
},
|
||||
{
|
||||
"key": "x",
|
||||
"command": "-magit.reset-mixed"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+u x",
|
||||
"command": "-magit.reset-hard"
|
||||
},
|
||||
{
|
||||
"key": "y",
|
||||
"command": "-magit.show-refs"
|
||||
},
|
||||
{
|
||||
"key": "y",
|
||||
"command": "vspacecode.showMagitRefMenu",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode == 'Normal'"
|
||||
},
|
||||
{
|
||||
"key": "g",
|
||||
"command": "-magit.refresh",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "g",
|
||||
"command": "vspacecode.showMagitRefreshMenu",
|
||||
"when": "editorTextFocus && editorLangId == 'magit' && vim.mode =~ /^(?!SearchInProgressMode|CommandlineInProgress).*$/"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "workbench.action.quickOpenSelectNext",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "workbench.action.quickOpenSelectPrevious",
|
||||
"when": "inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "selectNextSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "selectPrevSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "acceptSelectedSuggestion",
|
||||
"when": "suggestWidgetMultipleSuggestions && suggestWidgetVisible && textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "showNextParameterHint",
|
||||
"when": "editorFocus && parameterHintsMultipleSignatures && parameterHintsVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "showPrevParameterHint",
|
||||
"when": "editorFocus && parameterHintsMultipleSignatures && parameterHintsVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+j",
|
||||
"command": "selectNextCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k",
|
||||
"command": "selectPrevCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "acceptSelectedCodeAction",
|
||||
"when": "codeActionMenuVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+h",
|
||||
"command": "file-browser.stepOut",
|
||||
"when": "inFileBrowser"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+l",
|
||||
"command": "file-browser.stepIn",
|
||||
"when": "inFileBrowser"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+oem_4",
|
||||
"command": "whichkey.undoKey",
|
||||
"when": "whichkeyVisible"
|
||||
},
|
||||
{
|
||||
"key": "alt+e",
|
||||
"command": "editor.action.insertCursorAbove",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+up",
|
||||
"command": "-editor.action.insertCursorAbove",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+n",
|
||||
"command": "editor.action.insertCursorBelow",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+alt+down",
|
||||
"command": "-editor.action.insertCursorBelow",
|
||||
"when": "editorTextFocus"
|
||||
},
|
||||
// #endregion
|
||||
// #region Ctrl+W Remaps (Vim-like)
|
||||
{
|
||||
"key": "ctrl+w h",
|
||||
"command": "workbench.action.navigateLeft"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+h",
|
||||
"command": "workbench.action.toggleSidebarVisibility"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w i",
|
||||
"command": "workbench.action.navigateRight"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+i",
|
||||
"command": "workbench.action.toggleAuxiliaryBar"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w n",
|
||||
"command": "workbench.action.navigateDown"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+n",
|
||||
"command": "workbench.action.togglePanel"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w e",
|
||||
"command": "workbench.action.navigateUp"
|
||||
},
|
||||
{ // original ^w
|
||||
"key": "ctrl+w ctrl+w",
|
||||
"command": "workbench.action.closeActiveEditor",
|
||||
"when": "editorFocus || inSettingsEditor || inKeybindings || inWelcome"
|
||||
},
|
||||
{ // :only
|
||||
"key": "ctrl+w o",
|
||||
"command": "runCommands",
|
||||
"args": {
|
||||
"commands": [
|
||||
"workbench.action.joinAllGroups",
|
||||
"workbench.action.maximizeEditorHideSidebar"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w ctrl+w",
|
||||
"command": "workbench.action.closeGroup",
|
||||
"when": "activeEditorGroupEmpty && multipleEditorGroups"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w",
|
||||
"command": "-workbench.action.closeGroup",
|
||||
"when": "activeEditorGroupEmpty && multipleEditorGroups"
|
||||
},
|
||||
// #endregion
|
||||
// #region Emacs like Cursor Movement
|
||||
{
|
||||
"key": "ctrl+f",
|
||||
"command": "cursorRight",
|
||||
"when": "textInputFocus && !inlineEditIsVisible && !suggestWidgetVisible && !inlineSuggestionVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+b",
|
||||
"command": "cursorLeft",
|
||||
"when": "textInputFocus && !inlineEditIsVisible && !suggestWidgetVisible && !inlineSuggestionVisible"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "cursorDown",
|
||||
"when": "textInputFocus && !suggestWidgetVisible && !inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+p",
|
||||
"command": "cursorUp",
|
||||
"when": "textInputFocus && !suggestWidgetVisible && !inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+a",
|
||||
"command": "cursorHome",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+a",
|
||||
"command": "cursorEnd",
|
||||
"when": "editor.action.selectAll"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+a",
|
||||
"command": "editor.action.selectAll"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+e",
|
||||
"command": "cursorEnd",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+b",
|
||||
"command": "cursorWordStartLeft",
|
||||
"when": "textInputFocus"
|
||||
},
|
||||
{
|
||||
"key": "alt+f",
|
||||
"command": "cursorWordStartRight",
|
||||
"when": "textInputFocus && !inlineEditIsVisible && !suggestWidgetVisible && !inlineSuggestionVisible"
|
||||
},
|
||||
// #endregion
|
||||
{
|
||||
"key": "alt+q",
|
||||
"command": "vspacecode.space"
|
||||
},
|
||||
// #region Search View
|
||||
{ // Focus on search list, therefore can use n/e to move up/down
|
||||
"key": "escape",
|
||||
"command": "search.action.focusSearchList",
|
||||
"when": "searchViewletFocus && inputBoxFocus"
|
||||
},
|
||||
{ // Focus on main input box
|
||||
"key": "l",
|
||||
"command": "workbench.action.replaceInFiles",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "r",
|
||||
"command": "toggleSearchRegex",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "w",
|
||||
"command": "toggleSearchWholeWord",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "c",
|
||||
"command": "toggleSearchCaseSensitive",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "p",
|
||||
"command": "toggleSearchPreserveCase",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "i",
|
||||
"command": "search.action.focusFilesToInclude",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
},
|
||||
{
|
||||
"key": "shift+e",
|
||||
"command": "search.action.focusFilesToExclude",
|
||||
"when": "searchViewletFocus && !inputBoxFocus"
|
||||
}
|
||||
// #endregion
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue