-
Notifications
You must be signed in to change notification settings - Fork 169
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
fix(run_command): wrong logical condition #558
Conversation
Signed-off-by: Michele Calgaro <[email protected]>
Btw, great plugin! I switched from fzf.vim and fzf-lua has so much more to offer! Love it!! |
Thanks :)
Given this condition can’t happen with the current flow I’m curious how did you even find this issue? |
There are some things I would like to implement and contribute in future, so I started from the basic: reading the code and understanding what it does :-) |
Sounds amazing :) |
Two things I want to add are:
But don't get too excited :-) I will need some time since realistically I will only be able to spend 2-3 hours a week on this plugin, give or take. |
Oo this is a big one, gl :)
Why don’t you specify the winopts in the code actions mapping? As a general rule any option that can be specified via setup can be sent in a direct call, I.e.: :lua require'fzf-lua'.lsp_code_actions({ winopts = {…} }) The options get merged and override global/provider options so you can do pretty much whatever you want. |
As for “relative to the cursor” you can do that too, take a look at #545. |
I tried specifying
The code action window still shows up full screen.
Yes, I had found and tried that already, but thanks for the hint anyway :-) |
You’re correct, there is currently no separation aside from map_fzf('n', '<leader>la', "lsp_code_actions", {
desc = "code actions [LSP]",
winopts = {
win_height = 0.30,
win_width = 0.70,
win_row = 0.40,
}}) |
I finally got to the bottom of it. Regarding |
I agree, a separate section for fzf-lua/lua/fzf-lua/config.lua Lines 508 to 520 in 6203c4f
Feel free to take a stab at it if you want the PR or I’ll do it next time I get a chance. |
If it is not super urgent, I will be happy to work on it and propose a PR in coming weeks. It will be a good way for me to learn more about the plugin code ;-) |
560320a - guess you're left with the windows adaptation :-) |
Great, thanks for that! 👍 |
Although not directly exposed, the logical condition in run_command is wrong and makes the second part of the
and
pointless. Insteador
would do the correct evaluation.