Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support s mapping for EasyMotion to any surrounding word #1741

Open
fourcolors opened this issue May 23, 2017 · 8 comments
Open

Support s mapping for EasyMotion to any surrounding word #1741

fourcolors opened this issue May 23, 2017 · 8 comments

Comments

@fourcolors
Copy link

  • Click thumbs-up 👍 on this issue if you want it!
  • Click confused 😕 on this issue if not having it makes VSCodeVim unusable.

The VSCodeVim team prioritizes issues based on reaction count.


FEATURE REQUEST (choose one):

Environment:

  • VSCode Version: 1.12.2
  • VsCodeVim Version: .7.1
  • OS: MacOS
    Request:

I would REALLY like to map my s key to search forward AND backwards. I should be able to jump to any word and LINE BREAKS (please start including \n like normal EasyMotion does) with two-three characters.

I am currently using easymotion with VIM and this is a huge deal for me and a lot of people I know.

@Chillee
Copy link
Member

Chillee commented May 23, 2017

I'm thinking that Easymotion might be another good target for neovim integration. I'd rather not reimplement the entirety of EasyMotion again... I've opened up an issue here to ask about it: easymotion/vim-easymotion#331

@fourcolors
Copy link
Author

@Chillee right now you can't seem to get Neovim to do the easymotion thing, can you? Unless I'm mistaken.

@Chillee
Copy link
Member

Chillee commented Sep 7, 2017

@fourcolors Correct. EasyMotion does a bunch of hacks that make it difficult to integrate. @MaxfieldWalker has been on a tear implementing new EasyMotion features, so you might want to check some of the new features he's implemented out and see if they cover some of your use cases.

@maxfie1d
Copy link
Contributor

maxfie1d commented Sep 7, 2017

@fourcolors You can now map a single character to a easymotion action in the latest version of the extension with configuration like below.

    "vim.otherModesKeyBindingsNonRecursive": [
        {
            "before": [
                "s"
            ],
            "after": [
                "<leader>",
                "<leader>",
                "2",
                "s"
            ]
        }
    ]

@fourcolors
Copy link
Author

fourcolors commented Sep 7, 2017

@MaxfieldWalker Is it possible to make s do a search for the entire file I'm working in, basically adding a label for every word both ways? This is how I have it set up in VIM.

Basically, I just type s and it will auto search and label each word in the file, no need to search.

Also, search doesn't seem to search the whole file?

@fourcolors
Copy link
Author

basically i'm looking for this mapping nmap s <Plug>(easymotion-bd-w)

@maxfie1d
Copy link
Contributor

maxfie1d commented Sep 8, 2017

@fourcolors Unfortunately, bidirectional word motion is not supported so far, but it is easy to implement this, so I will work it on 👍

Basically search is done over the entire file, but the length of characters used for label name are 28, so 784(=28x28) labels shown at most.

@berknam
Copy link
Contributor

berknam commented Aug 4, 2020

@fourcolors Is this still an issue?

basically i'm looking for this mapping nmap s <Plug>(easymotion-bd-w)

This can already be done with <leader><leader><leader>bdw and you can map s to this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants