Welcome to Vifm Q&A, where you can ask questions about using Vifm. Registration is optional, anonymous posts are moderated. E-mail and GitHub logins are enabled.
0 votes
in vifm by

I might be missing something, but i was looking at a possible list of all events that can be used against the autocmd command. For now i have only seen the DirEnter, i imagine there might be more ?

The reason being is that i was looking at possibly making some use of the ipc / rpc communication to signal back to vim when a file is created, removed, renamed, and since there are multiple commands or keys that might produce such results (e.g. for rename - cw and :substitute), sounds like a good idea to have them handled in one central place.

1 Answer

0 votes
by

If there were other events, they would be documented. :autocmd supports only DirEnter at the moment.

You might want to look at app.fsop event in Lua which reports on copy/move/create/symlink/delete. Events there are less problematic than :autocmd by design (Bram said in one of talks that this command was a mistake because it can invoke an arbitrary command at semi-random place in code and create a mess).

by

Thanks, however it is not clear how to subscribe to this event, i saw there is documentation explaining the payload of fsop.

by

There is vifm.events.listen(). Should really be mentioned along event types.

You can also see a usage example here.

If you would like to make a bug report or feature request consider using GitHub, SourceForge or e-mail. Posting such things here is acceptable, but this is not a perfect place for them.
...