-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
fzf doesn't open file in normal mode (gvim/windows) #1169
Comments
The same result with only fzf plugin enabled: |
Since gdamore/tcell#159 (#1093 (comment)) is now merged, I'll rebuild Windows binary with the updated tcell and see if it helps. |
I can't reproduce ending up in insert mode, but I do need to press enter again to finish fzf process.
EDIT: Wait a minute, I might have missed something, let me check again. |
It's not actually end up with insert mode but it didn't exit terminal cleanly. Right after open file I can type characters into buffer. Thanks for looking into this issue. |
I have confirmed that the extra-enter problem is fixed with updated tcell. You can download the following alpha binary and test it. https://github.com/junegunn/fzf-bin/releases/download/alpha/fzf-0.17.2-alpha-windows_amd64.zip I first built fzf with the latest revision of tcell, but it didn't even run, panicking, so I had to update only to the point where the patch is merged, and all seemed fine. |
Thanks. Do you notice that we have a gap between opened buffer and title of it? It keeps the title If I have this setup in minimal vimrc: |
After |
@janlazo : Is there a way to make it faster to update? Should I open a ticket in vim?
|
call term_start('cmd', {'curwin': v:true, 'term_finish': 'close'}) acts like If this doesn't work, try function! fzf.on_exit(id, code, ...)
if !has('nvim') && has('gui_running')
redraw!
endif
endfunction |
Related: junegunn#1169 Title of current window does not update after the terminal buffer closes. Passing `term_finish: 'close'` to terminal options doesn't work because `curwin` is set. Force a screen update with `redraw!` which affects the window title(?). This screen update is not required in Neovim. Patch tested on GVim 8.0.1358
Related: junegunn#1169 Title of current window does not update after the terminal buffer closes. Passing `term_finish: 'close'` to terminal options doesn't work because `curwin` is set. Force a screen update with `redraw!` which affects the window title(?). This screen update is not required in Neovim. Patch tested on GVim 8.0.1358
Thanks, your PR fixed title update issue. |
I can reproduce the normal mode issue with your autocmd but I don't know why it happens. |
Thanks, I have to stop invoke |
The normal open issue with autocmd persist with version fzf 0.17.3. |
I don't have access to a Windows machine now, so I'm not sure, but does this help? autocmd VimEnter * silent! :redraw! | History<CR> And you mean it only happens when you trigger the command on VimEnter event? |
Sorry but it doesn't fix the issue. |
I've noticed something that maybe help on this. I can produce a weird behavior happens when issue commands |
Environment: gvim8 patch 1-1358 / windows 10, compiled with +terminal.
The issue: I have always press double
<ESC>
to exitsomething unclear
to bring to normal mode in vim after select a file to open from fzf. Video demo.I think terminal didn't exit properly so I asked in vim here. I try to solve the issue by searching through fzf codebase but silly me I can't find anything.
The text was updated successfully, but these errors were encountered: