-
-
Notifications
You must be signed in to change notification settings - Fork 181
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
multiple autocmd #155
Comments
Thanks for your suggestion. |
The multiple autocmds shown in your screenshot work as designed(except the g:Lf_VimResized), because they are attached to different event: LeaderF/autoload/leaderf/python/leaderf/instance.py Lines 89 to 92 in ddfcfe0
How to reproduce the "Press ENTER..." issue? Could you describe the steps in more detail please? |
only plug 'leaderf' source ~/.config/nvim/config/plugins.vim :LeaderfFunction sel, :q Press ENTER.... 英文好累, 若你的电脑不出现这种问题, 那就算了. 应该是我的电脑环境问题. 谢了. |
添加 silent! 之后, 就没有 Press Enter... 了. 不过, 退出很慢. 可以忍受. function! leaderf#Function#removeCache(bufNum) function! leaderf#Function#cleanup() |
你的neovim是哪里下载的?我装上试试这个问题。 |
https://github.com/neovim/neovim/releases
Nvim development (pre-release) build
…On Sun, May 13, 2018 at 9:24 AM, Yggdroot ***@***.***> wrote:
你的neovim是哪里下载的?我装上试试这个问题。
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#155 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AD8RYK4WvkcygpQzaSiethbd3UdBQgVXks5tx4tVgaJpZM4T8LeO>
.
|
你说的“Press Enter”的问题应该是neovim的bug。 :au VimLeave * py3 subprocess.Popen("cd", shell=True) 执行一个这样的命令,退出时就会有“Press Enter...” |
测试function! Xxxd()
py3 import subprocess; subprocess.Popen("cd", shell=True)
endfunction
" 退出不会
au VimLeave * silent! Xxxd
" 退出有问题 -> 循环 Press Enter ....
" au VimLeave * silent py3 import subprocess; subprocess.Popen("cd", shell=True)
" 加 silent! -> 没问题
" au VimLeave * silent! py3 import subprocess; subprocess.Popen("cd", shell=True)
" 未加 import subprocess; -> Press Enter 一次, 等待很久 -> 符合 issue
" au VimLeave * silent! py3 import subprocess; subprocess.Popen("cd", shell=True)
|
写错了 |
我知道加了 |
这是neovim gui的问题,因为终端nvim没问题。 |
开了个issue,neovim/neovim#8380 |
## init.vim
autocmd! VimLeave * call leaderf#BufTag#cleanup() | call
leaderf#File#cleanup() | call leaderf#Function#cleanup() | call GuiClose()
## leaderf
comment 上面三个 autocmd
保证 GuiClose 在最后.
现在瞬间退出.
…On Sun, May 13, 2018 at 9:04 PM, Yggdroot ***@***.***> wrote:
开了个issue,neovim/neovim#8380 <neovim/neovim#8380>
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#155 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AD8RYMHs4lEaTxWl4VXkP_6QT4g6xa96ks5tyC9EgaJpZM4T8LeO>
.
|
init.vimautocmd! VimLeave * call leaderf#BufTag#cleanup() | call leaderf#File#cleanup() | call leaderf#Function#cleanup() | call GuiClose() leaderfcomment 上面三个 autocmd 保证 GuiClose 在最后. 现在瞬间退出. |
使用 VimLeavePre, 也可以更好解决. |
不想因为neovim的bug,弄那么多弯弯绕的workaround,代码里已经有好多Neovim的workaround了,等Neovim稳定点再支持吧。 |
最近才 从 sublime text 转过来. 试一下 gvim 吧, 不过 等我看完 nvim 的文档 再说, 毕竟 nvim 是未来, 就像 py3 一样. 不是 bug 吧, VimLeavePre 我是看了别人代码才知道的, 我装的其他插件没用 VimLeave. 本地修改代码, 还是比较好. 话说, 动态添加 autocmd, 有点频繁, 添加一次 autocmd 就行. 最后, 我还是 comment 了这些动态代码, comment 了 非 fuzzyMatchC 的实现. thx. |
也许你是对的,使用VimLeavePre 确实没问题了,不过gVim使用VimLeave也没问题,我觉得这是neovim的bug。 |
确认是neovim-qt的bug,equalsraf/neovim-qt#394 . |
我还没怎么用neovim就已经遇到一堆bug了,我都开了十来个issue了,neovim/neovim#8382 |
NVIM v0.3.0-1201-g8ce639304
do:
:LeaderfBufTag
:LeaderfFunction
multi time
:au BufWipeout
--- Auto-Commands ---
BufWipeout
* call leaderf#BufTag#removeCache(expand(''))
call leaderf#BufTag#removeCache(expand(''))
call leaderf#Function#removeCache(expand(''))
call leaderf#Function#removeCache(expand(''))
call leaderf#BufTag#removeCache(expand(''))
call leaderf#BufTag#removeCache(expand(''))
and
VimLeave
* call GuiClose()
call leaderf#BufTag#cleanup()
call leaderf#BufTag#cleanup()
call leaderf#Function#cleanup()
...
call leaderf#Function#cleanup()
call leaderf#Function#cleanup()j
in python code
changed code
do:
LeaderfBufTag
LeaderfFunction
multi time:
:au BufWipeout
--- Auto-Commands ---
BufWipeout
* call leaderf#BufTag#removeCache(expand(''))
call leaderf#BufTag#removeCache(expand(''))
LFGRP BufWipeout
* call leaderf#Function#removeCache(expand(''))
BUT:
when nvim quit, still slow,
The text was updated successfully, but these errors were encountered: