aymericbeaumet / vim-symlink

:running: Automagically follow symlinks
MIT License
74 stars 10 forks source link

vim-symlink fails with 'autocmd nesting too deep' when opening help files with a symlinked config directory #6

Open andrewferrier opened 4 years ago

andrewferrier commented 4 years ago

Thanks for all your hard work on this great plugin! Unfortunately, I've found an annoying corner case which I've hit which affects my usage of help files.

Recreation steps:

echom system('git clone https://github.com/kristijanhusak/vim-packager ' . $HOME . '/.config/nvim/pack/packager/opt/vim-packager')

packadd vim-packager
call packager#init()
call packager#add('kristijanhusak/vim-packager', { 'type': 'opt' })
call packager#add('moll/vim-bbye') " needed for vim-symlink
call packager#add('junegunn/fzf', { 'do': './install --bin' })
call packager#add('junegunn/fzf.vim')
call packager#add('aymericbeaumet/vim-symlink')
call packager#install()
Error detected while processing function <SNR>29_on_buf_read[11]..<SNR>28_bdelete:
line   27:
E218: autocommand nesting too deep
E218: autocommand nesting too deep
E218: autocommand nesting too deep
Error detected while processing function <SNR>29_on_buf_read:
line   11:
E171: Missing :endif

Some observations:

andrewferrier commented 4 years ago

Let me know if there's anything else I can do to help debug...

andrewferrier commented 4 years ago

If you're interested, I've created a workaround for this issue in my fork here: https://github.com/andrewferrier/vim-symlink/commit/0c037b5891dde98c87f99eaa9cecc3b569b22c1e. It's probably not a proper fix, but it works for me for now.