question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support tpope/vim-unimpaired

See original GitHub issue

Is your feature request related to a problem? Please describe. I really miss using my [ and ] to navigate through lists in vim. Obviously not all those lists translate directly, but I find that many of them do.

Describe the solution you’d like Emulate the behavior of tpope/vim-unimpaired.

Describe alternatives you’ve considered I will begin implementing some of the functionality with keybindings.json.

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:19
  • Comments:6

github_iconTop GitHub Comments

8reactions
joeytwiddlecommented, Mar 18, 2021

A few more for you here: (the last few are not standard in vim-unimpaired)

{ "before": [ "[", "b" ], "commands": [ "workbench.action.previousEditor" ] },
{ "before": [ "]", "b" ], "commands": [ "workbench.action.nextEditor" ] },
{ "before": [ "[", "f" ], "commands": [ "workbench.view.explorer", "list.focusUp", "explorer.openAndPassFocus" ] },
{ "before": [ "]", "f" ], "commands": [ "workbench.view.explorer", "list.focusDown", "explorer.openAndPassFocus" ] },
{ "before": [ "[", "q" ], "commands": [ "search.action.focusPreviousSearchResult" ], "when": "hasSearchResult" },
{ "before": [ "]", "q" ], "commands": [ "search.action.focusNextSearchResult" ], "when": "hasSearchResult" },
{ "before": [ "[", "r" ], "commands": [ "references-view.prev" ], "when": "reference-list.hasResult" },
{ "before": [ "]", "r" ], "commands": [ "references-view.next" ], "when": "reference-list.hasResult" },
{ "before": [ "[", "l" ], "commands": [ "editor.action.marker.prevInFiles" ], "when": "editorTextFocus" },
{ "before": [ "]", "l" ], "commands": [ "editor.action.marker.nextInFiles" ], "when": "editorTextFocus" },
{ "before": [ "[", "g" ], "commands": [ "workbench.action.editor.previousChange" ], "when": "editorTextFocus" },
{ "before": [ "]", "g" ], "commands": [ "workbench.action.editor.nextChange" ], "when": "editorTextFocus" },
{ "before": [ "[", "w" ], "commands": [ "workbench.action.focusPreviousGroup" ] },
{ "before": [ "]", "w" ], "commands": [ "workbench.action.focusNextGroup" ] },

From my settings.json file.

5reactions
kiryphcommented, Jan 6, 2021

A first try to define the unimpaired mappings [<space>, ]<space>, [e, ]e:

{
    "vim.normalModeKeyBindings": [
        {
            "before": [ "[", " " ],
            "after": [ "O", "<Esc>", "j", "0" ]
        },
        {
            "before": [ "]", " " ],
            "after": [ "o", "<Esc>", "k", "0" ]
        },
        {
            "before": [ "]", "e" ],
            "commands": [ "editor.action.moveLinesDownAction" ]
        },
        {
            "before": [ "[", "e" ],
            "commands": [ "editor.action.moveLinesUpAction" ]
        }
    ],
    "vim.visualModeKeyBindings": [
        {
            "before": [ "]", "e" ],
            "commands": [ "editor.action.moveLinesDownAction" ]
        },
        {
            "before": [ "[", "e" ],
            "commands": [ "editor.action.moveLinesUpAction" ]
        }
    ]
}

Dot-repeat does not work for [e and ]e.

Read more comments on GitHub >

github_iconTop Results From Across the Web

unimpaired.vim: Pairs of handy bracket mappings - GitHub
command works with all operator mappings, and will work with the linewise mappings as well if you install repeat.vim. Installation. Install using your...
Read more >
unimpaired.vim - Pairs of handy bracket mappings : vim online
http://github.com/tpope/vim-unimpaired. install details. Unzip in ~/.vim (~\vimfiles on Windows). Use :helptags ~/.vim/doc to enable :help.
Read more >
What are all the mappings present in unimpaired.vim? - Reddit
The github page mentions only a few, and I assume there are more available but not described? Here are what I have read....
Read more >
https://raw.githubusercontent.com/rdlugosz/dotfile...
https://github.com/tpope/vim-unimpaired Plugin 'tpope/vim-unimpaired' ... provide support for textual snippets, similar to TextMate " or other Vim plugins.
Read more >
vim-unimpaired - roscidus.com
vim -unimpaired - unimpaired.vim: Pairs of handy bracket mappings ... This is a Zero Install feed. This software cannot be run as an...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found