-
Notifications
You must be signed in to change notification settings - Fork 196
fix: use :startinsert instead of feedkeys to switch to terminal mode #2034
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
base: main
Are you sure you want to change the base?
Conversation
Idk if we should touch this part, every time I messed with this (tried different strats) some edge case blew up (quite a few issues… including voodoo slowness), if the OP is the only issue so be it. Lines 225 to 246 in ea6d8ce
|
Sometimes use Another edge case(found just now): press
|
Generally I think Another way maybe simpler, cannot we just use buffer-local That's seems the recommanded way from document
|
This never happens to me even if I continue holding ctrl-g forever and stop randomly.
I’ve looked into many different methods, forgot why this one didn’t work, I’m willing to explore this again just know that this is somewhat sensitive and as of now nobody complains or has issues with it. |
I just found the root cause of the error is a bug of my another plugin... Now no problem in my config even with Maybe leave it here until some report more bug. I also implement inline screenshot (like nvim's |
I saw, looks great, if you are unsure about this PR and want the screenshots merged you can split it and I’ll merge. |
d923a4d
to
9cf367c
Compare
@phanen, I rebased and removed the CI commit since we already merged that, would you like to explore this further? I tested the autocmd for
|
Wrap |
TBH the current approach mostly works, I don’t know of any issues aside from what you wrote in the OP. |
``` nvim --headless --clean --server $NVIM --remote-send "<cmd>FzfLua complete_path<cr>" ```
If user has their own
startinsert
, e.g. in the following case,startinsert
is trigger by:term
, but later fzf term is focused.Technically user should not
startinsert
on an incorrect window, butcurrently there's no way to avoid it since builtin
startinsert
seemsdefered but
nvim_get_mode
is fast (return actual mode immediately).This PR periodly retry and only do
startinsert
innt
mode and on fzf term buffer.TODO: test