yegappan / fileselect

File Selector Vim Plugin
BSD 2-Clause "Simplified" License
18 stars 2 forks source link

vim9script changes require updates #19

Open benknoble opened 2 years ago

benknoble commented 2 years ago

For example:

E1263: cannot use name with # in Vim9 script, use export instead
yegappan commented 2 years ago

I have committed 447144c761b064b6bfa54f70fc641e7f29eaf6a3 to fix this problem. Can you try out the latest version of the plugin and let me know if you run into any issues?

benknoble commented 2 years ago

:Fileselect doesn't throw any errors now, but <Up> and <Down> turn into j and k in the filter (so they don't navigate the popup) and <Enter> doesn't open the file; I'm not sure why this is happening.

benknoble commented 2 years ago

I managed to sort of force it with :breakadd func fileselect#FileSelectShowMenu and then just n followed <Enter> repeatedly, but I got an error (hard to handle popups when in debug mode) and then the file appeared.

yegappan commented 2 years ago

To support toggling the fileselect popup with a map, I enabled processing mapped keys in the popup. This change may be causing this issue. Can you try removing the line 'mapping: 1' from popupAttr (line 343)?

benknoble commented 2 years ago

That did the trick for me, and explains the issues with Up/Down/Enter (I have mappings on all of those).

Unfortunately I don't see how to recover the toggle behavior though.