Last active
March 5, 2021 00:27
-
-
Save tduyng/e81edff7397e94e4fa8fb2c44eca2f7a to your computer and use it in GitHub Desktop.
Config vim in vscode
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Place your key bindings in this file to override the defaultsauto[] | |
// Place your key bindings in this file to override the defaultsauto[] | |
[ | |
{ | |
"key": "ctrl+k ctrl+u", | |
"command": "-editor.action.transformToUppercase", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+7", | |
"command": "workbench.action.terminal.toggleTerminal" | |
}, | |
{ | |
"key": "ctrl+alt+u", | |
"command": "editor.action.transformToUppercase" | |
}, | |
{ | |
"key": "ctrl+alt+l", | |
"command": "editor.action.transformToLowercase" | |
}, | |
{ | |
"key": "ctrl+tab", | |
"command": "workbench.action.nextEditor" | |
}, | |
{ | |
"key": "ctrl+shift+tab", | |
"command": "workbench.action.previousEditor" | |
}, | |
{ | |
"key": "ctrl+tab", | |
"command": "selectNextSuggestion", | |
"when": "editorTextFocus && suggestWidgetMultipleSuggestions && suggestWidgetVisible" | |
}, | |
{ | |
"key": "shift+tab", | |
"command": "selectPrevSuggestion", | |
"when": "editorTextFocus && suggestWidgetMultipleSuggestions && suggestWidgetVisible" | |
}, | |
{ | |
"key": "ctrl+alt+v", | |
"command": "toggleVim" | |
}, | |
{ | |
"key": "alt+j", | |
"command": "editor.action.moveLinesDownAction" | |
}, | |
{ | |
"key": "alt+k", | |
"command": "editor.action.moveLinesUpAction", | |
"when": "editorTextFocus && !editorReadonly" | |
}, | |
{ | |
"key": "shift+h+o", | |
"command": "editor.action.showHover", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+h", | |
"command": "workbench.action.focusLeftGroup", | |
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'" | |
}, | |
{ | |
"key": "ctrl+l", | |
"command": "workbench.action.focusRightGroup", | |
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'" | |
}, | |
{ | |
"key": "ctrl+alt+k", | |
"command": "workbench.action.focusAboveGroup", | |
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'" | |
}, | |
{ | |
"key": "ctrl+alt+j", | |
"command": "workbench.action.focusBelowGroup", | |
"when": "editorTextFocus && vim.active && vim.mode != 'Insert'" | |
}, | |
{ | |
"key": "ctrl+h", | |
"command": "list.collapse", | |
"when": "listFocus && !inputFocus" | |
}, | |
{ | |
"key": "ctrl+l", | |
"command": "list.expand", | |
"when": "listFocus && !inputFocus" | |
}, | |
{ | |
"key": "ctrl+k", | |
"command": "list.focusUp", | |
"when": "listFocus && !inputFocus" | |
}, | |
{ | |
"key": "ctrl+j", | |
"command": "list.focusDown", | |
"when": "listFocus && !inputFocus" | |
}, | |
{ | |
"key": "cmd+enter", | |
"command": "renameFile", | |
"when": "explorerViewletVisible && filesExplorerFocus" | |
}, | |
{ | |
"key": "enter", | |
"command": "-renameFile", | |
"when": "explorerViewletVisible && filesExplorerFocus" | |
}, | |
{ | |
"key": "enter", | |
"command": "list.select", | |
"when": "listFocus && !inputFocus" | |
}, | |
{ | |
"key": "ctrl+j", | |
"command": "selectNextSuggestion", | |
"when": "suggestWidgetVisible" | |
}, | |
{ | |
"key": "ctrl+k", | |
"command": "selectPrevSuggestion", | |
"when": "suggestWidgetVisible" | |
}, | |
{ | |
"key": "ctrl+j", | |
"command": "workbench.action.quickOpenSelectNext", | |
"when": "inQuickOpen" | |
}, | |
{ | |
"key": "ctrl+k", | |
"command": "workbench.action.quickOpenSelectPrevious", | |
"when": "inQuickOpen" | |
} | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"files.autoSave": "onFocusChange", | |
"vim.easymotion": true, | |
"vim.incsearch": true, | |
"vim.useSystemClipboard": true, | |
"vim.useCtrlKeys": true, | |
"vim.hlsearch": true, | |
"vim.sneak": true, | |
"vim.easymotionMarkerooundColor": "#020202", | |
"vim.normalModeKeyBindings": [ | |
{ | |
"before": ["<leader>", "d"], | |
"after": ["d", "d"] | |
}, | |
{ | |
"before": ["<tab>"], | |
"commands": ["workbench.action.nextEditor"] | |
}, | |
{ | |
"before": ["<S-tab>"], | |
"commands": ["workbench.action.previousEditor"] | |
} | |
], | |
"vim.insertModeKeyBindings": [ | |
{ | |
"before": ["j", "k"], | |
"after": ["<Esc>"] | |
} | |
], | |
"vim.visualModeKeyBindings": [ | |
{ | |
"before": [">"], | |
"after": [">", "g", "v"] | |
}, | |
{ | |
"before": ["<"], | |
"after": ["<", "g", "v"] | |
}, | |
{ | |
"before": ["<leader>", "c"], | |
"commands": ["editor.action.commentLine", "extension.vim_escape"] | |
} | |
], | |
"vim.normalModeKeyBindingsNonRecursive": [ | |
{ | |
"before": ["<leader>", "d"], | |
"after": ["d", "d"] | |
}, | |
{ | |
"before": ["<C-n>"], | |
"commands": [":nohl"] | |
}, | |
{ | |
"before": ["<leader>", "w"], | |
"commands": ["workbench.action.splitEditor"] | |
}, | |
{ | |
"before": ["<leader>", "t"], | |
"commands": ["workbench.action.toggleSidebarVisibility"] | |
}, | |
{ | |
"before": ["<leader>", "f"], | |
"commands": ["revealInExplorer"] | |
}, | |
{ | |
"before": ["<leader>", "h"], | |
"after": ["_"] | |
}, | |
{ | |
"before": ["<leader>", "l"], | |
"after": ["$"] | |
}, | |
{ | |
"before": ["<leader>", "c"], | |
"commands": ["editor.action.commentLine"] | |
}, | |
{ | |
"before": ["<leader>", "r", "e"], | |
"commands": ["editor.action.rename"] | |
}, | |
{ | |
"before": ["<leader>", "r", "f"], | |
"commands": ["fileutils.renameFile"] | |
}, | |
{ | |
"before": ["<leader>", "o", "g"], | |
"commands": ["workbench.action.showAllSymbols"] | |
}, | |
{ | |
"before": ["<leader>", "o", "o"], | |
"commands": ["workbench.action.showEditorsInActiveGroup"] | |
}, | |
{ | |
"before": ["<leader>", "o", "p"], | |
"commands": ["workbench.action.quickOpen"] | |
} | |
], | |
"vim.leader": "<space>", | |
"vim.handleKeys": { | |
"<C-a>": false, | |
"<C-f>": false, | |
// VS Code new marker @ next occurence | |
"<C-d>": false, | |
// Copy | |
"<C-c>": false, | |
// Cut | |
"<C-x>": false, | |
// Paste | |
"<C-v>": false, | |
"<C-z>": false, | |
"<C-y>": false, | |
"<C-k>": false, | |
"<C-b>": false, | |
"<C-w>": false | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment