Closed kuuote closed 1 month ago
plugin loaded check was break when calls plugin load multi times.
set rtp+=/path/to/github.com/vim-denops/denops.vim function s:reload() call denops#plugin#load('a', expand('<script>:h') .. '/a.ts') " 0 echo denops#plugin#is_loaded('a') endfunction function s:init() call denops#plugin#load('a', expand('<script>:h') .. '/a.ts') " 1 autocmd User DenopsPluginPost:a echo denops#plugin#is_loaded('a') autocmd User DenopsPluginPost:a call s:reload() endfunction autocmd User DenopsReady call s:init()
a.ts is any plugin. for example:
a.ts
export function main() { console.log("hello"); }
Place vimrc and a.ts to same directory.
vimrc
vim -Nu vimrc or nvim -u vimrc
vim -Nu vimrc
nvim -u vimrc
display 1 and 1
display 1 and 0
Linux horizon-bridge 6.9.8-arch1-1 #1 SMP PREEMPT_DYNAMIC Fri, 05 Jul 2024 22:11:24 +0000 x86_64 GNU/Linux
deno 1.44.4 (release, x86_64-unknown-linux-gnu)
VIM - Vi IMproved 9.1 (2024 Jan 02, compiled Jul 9 2024 08:24:57)
09e64956c2946bba0a060d0a0aaddde106753bd9
Describe the bug
plugin loaded check was break when calls plugin load multi times.
Provide a minimal vimrc with less than 50 lines to reproduce
a.ts
is any plugin. for example:How to reproduce the problem from Vim startup
Place
vimrc
anda.ts
to same directory.vim -Nu vimrc
ornvim -u vimrc
Expected behavior
display 1 and 1
Actual behavior
display 1 and 0
Your environment
Linux horizon-bridge 6.9.8-arch1-1 #1 SMP PREEMPT_DYNAMIC Fri, 05 Jul 2024 22:11:24 +0000 x86_64 GNU/Linux
deno 1.44.4 (release, x86_64-unknown-linux-gnu)
VIM - Vi IMproved 9.1 (2024 Jan 02, compiled Jul 9 2024 08:24:57)
09e64956c2946bba0a060d0a0aaddde106753bd9