kevinhwang91 / rnvimr

Make Ranger running in a floating window to communicate with Neovim via RPC
BSD 3-Clause "New" or "Revised" License
800 stars 17 forks source link

mouse_support broken #152

Closed fecet closed 1 year ago

fecet commented 1 year ago
Error detected while processing function rnvimr#toggle[16]..rnvimr#init[29]..rnvimr#enable_mouse_support:
line   23:
E122: Function <SNR>138_set_mouse_with_rnvimr already exists, add ! to replace it
Zeioth commented 1 year ago

Related to #151

Zeioth commented 1 year ago

@feced Under what circumstances does that happen? Could you provide more info?

The function is defined when rnvimr launches https://github.com/kevinhwang91/rnvimr/blob/8021cc2ea47a4a3c1cee05a555b3368c8e1d67be/autoload/rnvimr.vim#L185 And called here https://github.com/kevinhwang91/rnvimr/blob/8021cc2ea47a4a3c1cee05a555b3368c8e1d67be/autoload/rnvimr.vim#L246

that shouldn't normally happen.

fecet commented 1 year ago

More info: every first call of "RnvimrToggle" works, but if I quit it with :q<CR> in neovim(I map it by key Q) or open a file instead of quit with enter ":q" in ranger's command mode, the second "RnvimrToggle" will raise this error and I have to reload nvim.

kevinhwang91 commented 1 year ago

Will fix it later.