From d43ec80848b22825aa3528e43ae806c71540065b Mon Sep 17 00:00:00 2001 From: tyru Date: Wed, 2 May 2018 09:49:59 +0900 Subject: [PATCH 1/7] feat: add commands (same as [hjkl]) --- package.json | 20 ++++++++++++++++++++ src/actions/commands/actions.ts | 8 ++++---- 2 files changed, 24 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 448b4b8a22f..831bbd64767 100644 --- a/package.json +++ b/package.json @@ -210,11 +210,21 @@ "command": "extension.vim_navigateLeft", "when": "vim.use && vim.active && !editorTextFocus" }, + { + "key": "ctrl+h", + "command": "extension.vim_navigateCtrlH", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, { "key": "ctrl+w l", "command": "extension.vim_navigateRight", "when": "vim.use && vim.active && !editorTextFocus" }, + { + "key": "ctrl+l", + "command": "extension.vim_navigateCtrlL", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, { "key": "ctrl+w ctrl+w", "command": "extension.vim_navigateGroups", @@ -225,11 +235,21 @@ "command": "extension.vim_navigateDown", "when": "vim.use && vim.active && !editorTextFocus" }, + { + "key": "ctrl+j", + "command": "extension.vim_navigateCtrlJ", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, { "key": "ctrl+w k", "command": "extension.vim_navigateUp", "when": "vim.use && vim.active && !editorTextFocus" }, + { + "key": "ctrl+k", + "command": "extension.vim_navigateCtrlK", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, { "key": "ctrl+w", "command": "extension.vim_ctrl+w", diff --git a/src/actions/commands/actions.ts b/src/actions/commands/actions.ts index 62a5353efb4..c9b9e9e10c9 100644 --- a/src/actions/commands/actions.ts +++ b/src/actions/commands/actions.ts @@ -2555,7 +2555,7 @@ class CommandOnly extends BaseCommand { @RegisterAction class MoveToRightPane extends BaseCommand { modes = [ModeName.Normal, ModeName.Visual, ModeName.VisualLine]; - keys = [['', 'l'], ['', ''], ['']]; + keys = [['', 'l'], ['', ''], [''], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { vimState.postponedCodeViewChanges.push({ @@ -2570,7 +2570,7 @@ class MoveToRightPane extends BaseCommand { @RegisterAction class MoveToLowerPane extends BaseCommand { modes = [ModeName.Normal, ModeName.Visual, ModeName.VisualLine]; - keys = [['', 'j'], ['', ''], ['']]; + keys = [['', 'j'], ['', ''], [''], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { vimState.postponedCodeViewChanges.push({ @@ -2585,7 +2585,7 @@ class MoveToLowerPane extends BaseCommand { @RegisterAction class MoveToUpperPane extends BaseCommand { modes = [ModeName.Normal, ModeName.Visual, ModeName.VisualLine]; - keys = [['', 'k'], ['', ''], ['']]; + keys = [['', 'k'], ['', ''], [''], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { vimState.postponedCodeViewChanges.push({ @@ -2600,7 +2600,7 @@ class MoveToUpperPane extends BaseCommand { @RegisterAction class MoveToLeftPane extends BaseCommand { modes = [ModeName.Normal, ModeName.Visual, ModeName.VisualLine]; - keys = [['', 'h'], ['', ''], ['']]; + keys = [['', 'h'], ['', ''], [''], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { vimState.postponedCodeViewChanges.push({ From e9c401aaa3906f7db0bda0df45a731ac889d1597 Mon Sep 17 00:00:00 2001 From: tyru Date: Wed, 2 May 2018 09:57:28 +0900 Subject: [PATCH 2/7] feat: add command --- src/actions/commands/actions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/actions/commands/actions.ts b/src/actions/commands/actions.ts index c9b9e9e10c9..3d3f19be51e 100644 --- a/src/actions/commands/actions.ts +++ b/src/actions/commands/actions.ts @@ -2543,7 +2543,7 @@ class CommandQuit extends BaseCommand { @RegisterAction class CommandOnly extends BaseCommand { modes = [ModeName.Normal]; - keys = [['', 'o'], ['', 'C-o']]; + keys = [['', 'o'], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { new OnlyCommand({}).execute(); From 4aaaa0c22119a012c46de5e96345e3cd82082cfe Mon Sep 17 00:00:00 2001 From: tyru Date: Wed, 2 May 2018 10:04:28 +0900 Subject: [PATCH 3/7] feat: add , commands --- package.json | 10 ++++++++++ src/actions/commands/actions.ts | 4 ++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 831bbd64767..5eaaa914c1f 100644 --- a/package.json +++ b/package.json @@ -255,6 +255,16 @@ "command": "extension.vim_ctrl+w", "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, + { + "key": "ctrl+q", + "command": "extension.vim_winCtrlQ", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, + { + "key": "ctrl+v", + "command": "extension.vim_winCtrlV", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, { "key": "ctrl+c", "command": "extension.vim_ctrl+c", diff --git a/src/actions/commands/actions.ts b/src/actions/commands/actions.ts index 3d3f19be51e..193b8625647 100644 --- a/src/actions/commands/actions.ts +++ b/src/actions/commands/actions.ts @@ -2531,7 +2531,7 @@ class CommandNavigateLastBOL extends BaseCommand { @RegisterAction class CommandQuit extends BaseCommand { modes = [ModeName.Normal]; - keys = ['', 'q']; + keys = [['', 'q'], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { new QuitCommand({}).execute(); @@ -2635,7 +2635,7 @@ class BaseTabCommand extends BaseCommand { @RegisterAction class VerticalSplit extends BaseCommand { modes = [ModeName.Normal, ModeName.Visual, ModeName.VisualLine]; - keys = ['', 'v']; + keys = [['', 'v'], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { vimState.postponedCodeViewChanges.push({ From c7dfa836f970a20c106ce2ff6f47fc3c38b4b30e Mon Sep 17 00:00:00 2001 From: tyru Date: Fri, 4 May 2018 07:43:10 +0900 Subject: [PATCH 4/7] feat: add , c --- src/actions/commands/actions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/actions/commands/actions.ts b/src/actions/commands/actions.ts index 193b8625647..802c0d8a49b 100644 --- a/src/actions/commands/actions.ts +++ b/src/actions/commands/actions.ts @@ -2531,7 +2531,7 @@ class CommandNavigateLastBOL extends BaseCommand { @RegisterAction class CommandQuit extends BaseCommand { modes = [ModeName.Normal]; - keys = [['', 'q'], ['', '']]; + keys = [['', 'q'], ['', ''], ['', 'c'], ['', '']]; public async exec(position: Position, vimState: VimState): Promise { new QuitCommand({}).execute(); From 4e327ad5e873ec4e179ef28a08bb0e06607d428e Mon Sep 17 00:00:00 2001 From: tyru Date: Fri, 4 May 2018 11:15:51 +0900 Subject: [PATCH 5/7] fix: fix vim.use{key}, remove 2 key combos --- package.json | 42 ++++++------------------------------------ 1 file changed, 6 insertions(+), 36 deletions(-) diff --git a/package.json b/package.json index 5eaaa914c1f..a047a2a80ff 100644 --- a/package.json +++ b/package.json @@ -205,50 +205,25 @@ "command": "extension.vim_ctrl+]", "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, - { - "key": "ctrl+w h", - "command": "extension.vim_navigateLeft", - "when": "vim.use && vim.active && !editorTextFocus" - }, { "key": "ctrl+h", "command": "extension.vim_navigateCtrlH", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" - }, - { - "key": "ctrl+w l", - "command": "extension.vim_navigateRight", - "when": "vim.use && vim.active && !editorTextFocus" + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+l", "command": "extension.vim_navigateCtrlL", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" - }, - { - "key": "ctrl+w ctrl+w", - "command": "extension.vim_navigateGroups", - "when": "vim.use && vim.active && !editorTextFocus" - }, - { - "key": "ctrl+w j", - "command": "extension.vim_navigateDown", - "when": "vim.use && vim.active && !editorTextFocus" + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+j", "command": "extension.vim_navigateCtrlJ", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" - }, - { - "key": "ctrl+w k", - "command": "extension.vim_navigateUp", - "when": "vim.use && vim.active && !editorTextFocus" + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+k", "command": "extension.vim_navigateCtrlK", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+w", @@ -258,12 +233,12 @@ { "key": "ctrl+q", "command": "extension.vim_winCtrlQ", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+v", "command": "extension.vim_winCtrlV", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+c", @@ -360,11 +335,6 @@ "command": "list.collapse", "when": "listFocus && !inputFocus" }, - { - "key": "g g", - "command": "list.focusFirst", - "when": "listFocus && !inputFocus" - }, { "key": "shift+G", "command": "list.focusLast", From 13de31c4b48925dd3b5b1a975f83f5e4c7ff8c95 Mon Sep 17 00:00:00 2001 From: tyru Date: Fri, 4 May 2018 12:13:18 +0900 Subject: [PATCH 6/7] refactor: sort contributes.commands alphabetically --- package.json | 298 +++++++++++++++++++++++++-------------------------- 1 file changed, 149 insertions(+), 149 deletions(-) diff --git a/package.json b/package.json index 7efdfbf608f..a70af9227ff 100644 --- a/package.json +++ b/package.json @@ -72,73 +72,69 @@ "when": "editorTextFocus && vim.active && !inDebugRepl" }, { - "key": "cmd+left", - "command": "extension.vim_cmd+left", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.mode != 'Insert'" + "key": "Backspace", + "command": "extension.vim_backspace", + "when": "editorTextFocus && vim.active && !inDebugRepl" }, { - "key": "cmd+right", - "command": "extension.vim_cmd+right", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.mode != 'Insert'" + "key": "Delete", + "command": "extension.vim_delete", + "when": "editorTextFocus && vim.active && vim.mode != 'Insert' && !inDebugRepl" }, { - "key": "cmd+d", - "command": "extension.vim_cmd+d", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "tab", + "command": "extension.vim_tab", + "when": "editorFocus && vim.active && vim.mode != 'Insert' && !inDebugRepl" }, { - "key": "cmd+a", - "command": "extension.vim_cmd+a", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.mode != 'Insert'" + "key": "left", + "command": "extension.vim_left", + "when": "editorTextFocus && vim.active && !inDebugRepl" }, { - "key": "ctrl+d", - "command": "extension.vim_ctrl+d", + "key": "right", + "command": "extension.vim_right", "when": "editorTextFocus && vim.active && !inDebugRepl" }, { - "key": "ctrl+alt+down", - "linux": "shift+alt+down", - "mac": "cmd+alt+down", - "command": "extension.vim_cmd+alt+down", - "when": "editorTextFocus && vim.active && !inDebugRepl" + "key": "up", + "command": "extension.vim_up", + "when": "editorTextFocus && vim.active && !inDebugRepl && !suggestWidgetVisible && !suggestWidgetMultipleSuggestions" }, { - "key": "ctrl+alt+up", - "linux": "shift+alt+up", - "mac": "cmd+alt+up", - "command": "extension.vim_cmd+alt+up", - "when": "editorTextFocus && vim.active && !inDebugRepl" + "key": "down", + "command": "extension.vim_down", + "when": "editorTextFocus && vim.active && !inDebugRepl && !suggestWidgetVisible && !suggestWidgetMultipleSuggestions" }, { - "key": "Backspace", - "command": "extension.vim_backspace", - "when": "editorTextFocus && vim.active && !inDebugRepl" + "key": "h", + "command": "list.collapse", + "when": "listFocus && !inputFocus" }, { - "key": "shift+backspace", - "command": "extension.vim_shift+backspace", - "when": "editorTextFocus && vim.active && vim.use && vim.mode == 'SearchInProgressMode' && !inDebugRepl" + "key": "j", + "command": "list.focusDown", + "when": "listFocus && !inputFocus" }, { - "key": "Delete", - "command": "extension.vim_delete", - "when": "editorTextFocus && vim.active && vim.mode != 'Insert' && !inDebugRepl" + "key": "k", + "command": "list.focusUp", + "when": "listFocus && !inputFocus" }, { - "key": "tab", - "command": "extension.vim_tab", - "when": "editorFocus && vim.active && vim.mode != 'Insert' && !inDebugRepl" + "key": "l", + "command": "list.select", + "when": "listFocus && !inputFocus" }, { - "key": "ctrl+r", - "command": "extension.vim_ctrl+r", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "o", + "command": "list.toggleExpand", + "when": "listFocus && !inputFocus" }, { - "key": "ctrl+f", - "command": "extension.vim_ctrl+f", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+a", + "command": "extension.vim_ctrl+a", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+b", @@ -146,19 +142,19 @@ "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" }, { - "key": "ctrl+j", - "command": "extension.vim_ctrl+j", - "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" + "key": "ctrl+c", + "command": "extension.vim_ctrl+c", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.overrideCtrlC" }, { - "key": "ctrl+k", - "command": "extension.vim_ctrl+k", - "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" + "key": "ctrl+d", + "command": "extension.vim_ctrl+d", + "when": "editorTextFocus && vim.active && !inDebugRepl" }, { - "key": "ctrl+h", - "command": "extension.vim_ctrl+h", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+d", + "command": "list.focusPageDown", + "when": "listFocus && !inputFocus" }, { "key": "ctrl+e", @@ -166,19 +162,19 @@ "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+y", - "command": "extension.vim_ctrl+y", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+f", + "command": "extension.vim_ctrl+f", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+u", - "command": "extension.vim_ctrl+u", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+h", + "command": "extension.vim_ctrl+h", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+o", - "command": "extension.vim_ctrl+o", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+h", + "command": "extension.vim_navigateCtrlH", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+i", @@ -186,29 +182,24 @@ "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+v", - "command": "extension.vim_ctrl+v", - "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" - }, - { - "key": "cmd+v", - "command": "extension.vim_cmd+v", - "when": "editorTextFocus && vim.active && vim.use && vim.mode == 'SearchInProgressMode' && !inDebugRepl" + "key": "ctrl+j", + "command": "extension.vim_ctrl+j", + "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" }, { - "key": "ctrl+[", - "command": "extension.vim_ctrl+[", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+j", + "command": "extension.vim_navigateCtrlJ", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+]", - "command": "extension.vim_ctrl+]", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+k", + "command": "extension.vim_ctrl+k", + "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" }, { - "key": "ctrl+h", - "command": "extension.vim_navigateCtrlH", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+k", + "command": "extension.vim_navigateCtrlK", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+l", @@ -216,19 +207,19 @@ "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+j", - "command": "extension.vim_navigateCtrlJ", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+n", + "command": "extension.vim_ctrl+n", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+k", - "command": "extension.vim_navigateCtrlK", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+o", + "command": "extension.vim_ctrl+o", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+w", - "command": "extension.vim_ctrl+w", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+p", + "command": "extension.vim_ctrl+p", + "when": "suggestWidgetVisible && vim.active && vim.use" }, { "key": "ctrl+q", @@ -236,50 +227,65 @@ "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+v", - "command": "extension.vim_winCtrlV", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+r", + "command": "extension.vim_ctrl+r", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+c", - "command": "extension.vim_ctrl+c", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.overrideCtrlC" + "key": "ctrl+t", + "command": "extension.vim_ctrl+t", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "cmd+c", - "command": "extension.vim_cmd+c", - "when": "editorTextFocus && vim.active && vim.use && vim.overrideCopy && !inDebugRepl" + "key": "ctrl+u", + "command": "extension.vim_ctrl+u", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "ctrl+a", - "command": "extension.vim_ctrl+a", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+u", + "command": "list.focusPageUp", + "when": "listFocus && !inputFocus" }, { - "key": "ctrl+n", - "command": "extension.vim_ctrl+n", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + "key": "ctrl+v", + "command": "extension.vim_ctrl+v", + "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" }, { - "key": "ctrl+p", - "command": "extension.vim_ctrl+p", - "when": "suggestWidgetVisible && vim.active && vim.use" + "key": "ctrl+v", + "command": "extension.vim_winCtrlV", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, + { + "key": "ctrl+w", + "command": "extension.vim_ctrl+w", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+x", "command": "extension.vim_ctrl+x", "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, + { + "key": "ctrl+y", + "command": "extension.vim_ctrl+y", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, + { + "key": "ctrl+[", + "command": "extension.vim_ctrl+[", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, + { + "key": "ctrl+]", + "command": "extension.vim_ctrl+]", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" + }, { "key": "ctrl+shift+2", "command": "extension.vim_ctrl+shift+2", "when": "editorTextFocus && vim.active && vim.use" }, - { - "key": "ctrl+t", - "command": "extension.vim_ctrl+t", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" - }, { "key": "ctrl+pagedown", "command": "extension.vim_ctrl+pagedown", @@ -291,64 +297,58 @@ "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "left", - "command": "extension.vim_left", - "when": "editorTextFocus && vim.active && !inDebugRepl" - }, - { - "key": "right", - "command": "extension.vim_right", - "when": "editorTextFocus && vim.active && !inDebugRepl" - }, - { - "key": "up", - "command": "extension.vim_up", - "when": "editorTextFocus && vim.active && !inDebugRepl && !suggestWidgetVisible && !suggestWidgetMultipleSuggestions" + "key": "shift+G", + "command": "list.focusLast", + "when": "listFocus && !inputFocus" }, { - "key": "down", - "command": "extension.vim_down", - "when": "editorTextFocus && vim.active && !inDebugRepl && !suggestWidgetVisible && !suggestWidgetMultipleSuggestions" + "key": "shift+backspace", + "command": "extension.vim_shift+backspace", + "when": "editorTextFocus && vim.active && vim.use && vim.mode == 'SearchInProgressMode' && !inDebugRepl" }, { - "key": "j", - "command": "list.focusDown", - "when": "listFocus && !inputFocus" + "key": "cmd+left", + "command": "extension.vim_cmd+left", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.mode != 'Insert'" }, { - "key": "k", - "command": "list.focusUp", - "when": "listFocus && !inputFocus" + "key": "cmd+right", + "command": "extension.vim_cmd+right", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.mode != 'Insert'" }, { - "key": "o", - "command": "list.toggleExpand", - "when": "listFocus && !inputFocus" + "key": "cmd+a", + "command": "extension.vim_cmd+a", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl && vim.mode != 'Insert'" }, { - "key": "l", - "command": "list.select", - "when": "listFocus && !inputFocus" + "key": "cmd+c", + "command": "extension.vim_cmd+c", + "when": "editorTextFocus && vim.active && vim.use && vim.overrideCopy && !inDebugRepl" }, { - "key": "h", - "command": "list.collapse", - "when": "listFocus && !inputFocus" + "key": "cmd+d", + "command": "extension.vim_cmd+d", + "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { - "key": "shift+G", - "command": "list.focusLast", - "when": "listFocus && !inputFocus" + "key": "cmd+v", + "command": "extension.vim_cmd+v", + "when": "editorTextFocus && vim.active && vim.use && vim.mode == 'SearchInProgressMode' && !inDebugRepl" }, { - "key": "ctrl+d", - "command": "list.focusPageDown", - "when": "listFocus && !inputFocus" + "key": "ctrl+alt+down", + "linux": "shift+alt+down", + "mac": "cmd+alt+down", + "command": "extension.vim_cmd+alt+down", + "when": "editorTextFocus && vim.active && !inDebugRepl" }, { - "key": "ctrl+u", - "command": "list.focusPageUp", - "when": "listFocus && !inputFocus" + "key": "ctrl+alt+up", + "linux": "shift+alt+up", + "mac": "cmd+alt+up", + "command": "extension.vim_cmd+alt+up", + "when": "editorTextFocus && vim.active && !inDebugRepl" } ], "configuration": { From 1968b0f6cd6b0429b8e05615f8be5c565b16e1f2 Mon Sep 17 00:00:00 2001 From: tyru Date: Fri, 4 May 2018 18:38:05 +0900 Subject: [PATCH 7/7] fix: remove duplicate keys, restore gg --- package.json | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) diff --git a/package.json b/package.json index a70af9227ff..a92adcee58e 100644 --- a/package.json +++ b/package.json @@ -106,6 +106,11 @@ "command": "extension.vim_down", "when": "editorTextFocus && vim.active && !inDebugRepl && !suggestWidgetVisible && !suggestWidgetMultipleSuggestions" }, + { + "key": "g g", + "command": "list.focusFirst", + "when": "listFocus && !inputFocus" + }, { "key": "h", "command": "list.collapse", @@ -171,11 +176,6 @@ "command": "extension.vim_ctrl+h", "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, - { - "key": "ctrl+h", - "command": "extension.vim_navigateCtrlH", - "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" - }, { "key": "ctrl+i", "command": "extension.vim_ctrl+i", @@ -184,21 +184,11 @@ { "key": "ctrl+j", "command": "extension.vim_ctrl+j", - "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" - }, - { - "key": "ctrl+j", - "command": "extension.vim_navigateCtrlJ", "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { "key": "ctrl+k", "command": "extension.vim_ctrl+k", - "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" - }, - { - "key": "ctrl+k", - "command": "extension.vim_navigateCtrlK", "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, { @@ -249,11 +239,6 @@ { "key": "ctrl+v", "command": "extension.vim_ctrl+v", - "when": "editorTextFocus && vim.active && vim.use && vim.mode != 'Insert' && !inDebugRepl" - }, - { - "key": "ctrl+v", - "command": "extension.vim_winCtrlV", "when": "editorTextFocus && vim.active && vim.use && !inDebugRepl" }, {