-
Notifications
You must be signed in to change notification settings - Fork 467
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
feat(plugins): add flash.nvim
to replace clever-f.vim
#926
Conversation
I'm not sure If I should remove |
IMO we may need to do some other cleanups as several plugins will be deprecated due to this PR, and their keymaps should bind to this new integration. |
21748b2: remove |
What's the reason to add this, it doesn't do more than hop and treehopper |
You can check out it's README.md. In short, it combines all three plugins (include |
After scanning through the introduction of this plugin, one of the most significant benefits that came to my mind was it integrates all motion commands together, which signifies a high probability of simplifying our code. But I haven't checked its implementation detail yet - |
I agree, but I'm only using some of the basic features of comments.nvim. Can you explain how it conflicts with |
I support to use flash to replace clever-f and then users can freely choose whether to use it as a replacement for hop. IMO hop, tree-hopper and incremental-selection covers the functionalities of flash very well and they are already in this repo. I'm also implementing folke/flash.nvim#52 on the top of TS. And #494 (comment) cmp also enhance / |
They had the advantage over each other and I didn't remove |
Hmm FWIW this way the drawbacks of this plugin outweigh the potential benefits it may bring. I mean, why do we need to replace a single working plugin with a highly-integrated one? We can add wildfire.vim for custom textobjects and have each plugin do their respective functionality, which will also reduce maintenance pressure as no plugin will experience way faster iterations.
Ah thanks for providing a working example! I'm working on this, trying to cover some cornercases 😄 |
This is a little bit different IMO, |
I've been using |
Maybe we can only enable this specific feature? b/c we'll probably load |
Yeah I'm trying to address this issue (if we can collect and import these missing items using external sources) |
You mean |
I mean we can only enable "fast jump in search mode". This way we can avoid introduing breaking changes - if users do want to activate some of |
I agree, as if we should replace
|
I tend to agree with @Jint-lzxy, maybe we can introduce flash.nvim gradually, first for just |
Hmm I haven't encountered this issue before, but
Yeah that's why I said "we can only enable 'fast jump in search mode'" |
I kind of forgot how to reproduce that bug, if I finish the JUMP then there is no highlight at that point. But when I press |
Another thing, as flash takes place of statusline, and it's prompt is configurable, we can make it look like lualine section a, maybe better. |
Good point, I will take a look in the morning. |
Before I read the readme of But after reading the readme, I found it was THE motion plugin I ever wanted an year ago! If Considering there might be lots of ppl using the repo, I think it would be better to replace one functionality/plugin at each release, as aarnphm implied. Not sure about the status line thingy tho, I didn't look super deep into |
Also quite in favor of this (as per #926 (comment)) - we can gradually complete such transition like what we did in #920 and #921. Cause from the user's perspective, those individual PRs only adds a few files, along with several trivial (and "conflict-friendly") changes that are easy to adopt. This can also effectively avoid breaking changes (which can be quite annoying in some cases). |
Maybe it's time to promote this PR @YuCao16 ? |
Yes, give me sometime. |
Sorry for the long delay, what other changes do I need to make before merge? @Jint-lzxy @ayamir |
It's undoubted that |
My use case is that flash.nvim is a perfect replacement for clever-f, can be used with wilder, but replacing hop requires a bit of a learning curve. I don't even use remote, we don't need to configure all the features of a plugin. |
Signed-off-by: ayamir <lgt986452565@gmail.com>
IMO it's better to leave the decision to users. It looks good to me now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the delay. This PR LGTM now 😸 I explicitly disabled flash.nvim
's search mode integration (but kept the related keymap to facilitate user customization), b/c IMHO this may not be the point that some users expect to change, and there're compatibility issues with wilder.nvim
(correct me if I'm wrong :D)
flash.nvim
flash.nvim
to replace clever-f.nvim
flash.nvim
to replace clever-f.nvim
flash.nvim
to replace clever-f.vim
I agree, LGTM, thanks for your help! |
* disable enforce_regular_tabs to fix unique name not working * add flash.nvim * disable multi_window * fixup!: remove comment lines in keymap, add NOTEs for users. Signed-off-by: ayamir <lgt986452565@gmail.com> * move flash_ecs to keymap/helpers.lua and rename to _flash_esc * feat(flash): support user-override * pref: explicitly disable `flash.search` by default * chore: sort keymap helpers * fix typo * fixup! fix typo --------- Signed-off-by: ayamir <lgt986452565@gmail.com> Co-authored-by: ayamir <lgt986452565@gmail.com> Co-authored-by: Jint-lzxy <50296129+Jint-lzxy@users.noreply.github.com>
* disable enforce_regular_tabs to fix unique name not working * add flash.nvim * disable multi_window * fixup!: remove comment lines in keymap, add NOTEs for users. Signed-off-by: ayamir <lgt986452565@gmail.com> * move flash_ecs to keymap/helpers.lua and rename to _flash_esc * feat(flash): support user-override * pref: explicitly disable `flash.search` by default * chore: sort keymap helpers * fix typo * fixup! fix typo --------- Signed-off-by: ayamir <lgt986452565@gmail.com> Co-authored-by: ayamir <lgt986452565@gmail.com> Co-authored-by: Jint-lzxy <50296129+Jint-lzxy@users.noreply.github.com>
#494 (comment)
core/mapping.lua
, I wrote a function for users who don't haveflash.nvim
installed.flash.nvim
inkeymap/editor.lua
, because I use the defaults
quite often.