el-iot / buffer-tree-explorer

A simple vim-plugin for rendering your open buffers into an interactive ascii-tree to allow for easy navigation / management.
Other
22 stars 4 forks source link

Expose API for extensions #6

Open poetaman opened 3 years ago

poetaman commented 3 years ago

I recently came across this plugin, and wonder if you can create/expose two functions for users?

function inputfilelist: Instead of loading buffer list, it will load the list of paths user provides. This way users can write their custom extensions using this your codebase, perhaps even other plugins.

function pathundercursor: When called, this will return the path under the cursor in the buffer tree explorer buffer.

As a sidenote, you could probably source the navigation code from https://github.com/mhinz/vim-tree, it has a navigation feature that keeps the cursor on the first character of directory/file name.