update vscode

This commit is contained in:
Yu Squire[ Yu, Tsung-Ying ] 2024-11-01 11:48:06 +08:00
parent df9afc9fc6
commit 0071d65eab
2 changed files with 40 additions and 22 deletions

View File

@ -33,6 +33,16 @@
"command": "selectPrevSuggestion", "command": "selectPrevSuggestion",
"when": "suggestWidgetVisible" "when": "suggestWidgetVisible"
}, },
{
"key": "ctrl+j",
"command": "selectNextCodeAction",
"when": "codeActionMenuVisible"
},
{
"key": "ctrl+k",
"command": "selectPrevCodeAction",
"when": "codeActionMenuVisible"
},
{ {
"key": "ctrl+j", "key": "ctrl+j",
"command": "workbench.action.quickOpenSelectNext", "command": "workbench.action.quickOpenSelectNext",
@ -43,6 +53,17 @@
"command": "workbench.action.quickOpenSelectPrevious", "command": "workbench.action.quickOpenSelectPrevious",
"when": "inQuickOpen" "when": "inQuickOpen"
}, },
// Code suggest and quick fix
{
"key": "ctrl+/",
"command": "editor.action.triggerSuggest",
"when": "editorTextFocus && !editorReadonly && vim.active"
},
{
"key": "ctrl+.",
"command": "editor.action.quickFix",
"when": "editorTextFocus && !editorReadonly && vim.active"
},
// File management // File management
{ {
"key": "ctrl+n", "key": "ctrl+n",
@ -84,19 +105,10 @@
"command": "workbench.action.terminal.focusPrevious", "command": "workbench.action.terminal.focusPrevious",
"when": "terminalFocus" "when": "terminalFocus"
}, },
// Outline
{ {
"key": "ctrl+shift+l", "key": "escape",
"command": "workbench.action.positionPanelRight", "command": "workbench.action.toggleSidebarVisibility",
"when": "terminalFocus" "when": "view.outline.visible"
},
{
"key": "ctrl+shift+j",
"command": "workbench.action.positionPanelBottom",
"when": "terminalFocus"
},
{
"key": "ctrl+shift+h",
"command": "workbench.action.positionPanelLeft",
"when": "terminalFocus"
} }
] ]

View File

@ -19,11 +19,17 @@
}, },
"editor.minimap.enabled": false, "editor.minimap.enabled": false,
// Vim settings // Vim settings
"extensions.experimental.affinity": {
"vscodevim.vim": 1,
"asvetliakov.vscode-neovim": 1
},
"vim.leader": "<Space>", "vim.leader": "<Space>",
"vim.hlsearch": true, "vim.hlsearch": true,
"vim.easymotion": true, "vim.easymotion": true,
"vim.useSystemClipboard": true, "vim.useSystemClipboard": true,
"vim.smartRelativeLine": true, "vim.smartRelativeLine": true,
"vim.statusBarColorControl": false,
"vim.ignorecase": true,
"vim.normalModeKeyBindings": [ "vim.normalModeKeyBindings": [
{ {
"before": [ "before": [
@ -245,15 +251,6 @@
} }
], ],
"vim.visualModeKeyBindings": [ "vim.visualModeKeyBindings": [
{
"before": [
"j",
"k"
],
"after": [
"<Esc>"
]
},
{ {
"before": [ "before": [
"<Tab>" "<Tab>"
@ -269,6 +266,15 @@
"commands": [ "commands": [
"editor.action.outdentLines" "editor.action.outdentLines"
] ]
},
{
"before": [
"p"
],
"commands": [
"editor.action.clipboardPasteAction",
"extension.vim_escape"
]
} }
] ]
} }