Questions tagged [plugin-development]
Questions about the development of plugins for Vim. *Do not* use this tag for questions about a specific plugin.
9
questions
2
votes
2
answers
91
views
How can I test the script-local functions of my plugin?
I have the feeling that the answer is you can't, but I'd like to be sure about it.
My plugin has some s:function-name functions, and one plugin-name#function-name function that uses the former ones.
...
1
vote
0
answers
15
views
Vader for testing plugin that eases window navigation
Some time ago I wrote a plugin for easy window navigation, and now I was trying to write some test for it, using Vader, which I knew nothing about until a few hours ago.
Basically, with my plugin ...
3
votes
1
answer
439
views
Vim feedkeys in operator pending mode
I'm trying to build a very simple plugin that allows for pressing a keymapping <Leader>, to call a function that prompts for a single keypress:
function! ControlKey()
echo "Key → <C-Key&...
0
votes
1
answer
108
views
Best way to avoid clobbering other vim plugins with global commands
I'm developing a vim plugin. There will be some global-level functionality that's not specific to a particular filetype.
Is there some kind of registry of commands being used by vim packages?
How ...
1
vote
0
answers
74
views
Live search in temporary buffer
Faced a problem that I cannot force the buffer with results and the input field to work together, but not in turn (like in CtrlP)
function! s:SearchByListFiles(all_files, query)
let searched = []
...
1
vote
0
answers
276
views
Subscribe to a buffer event in a lua plugin
I want to write a plugin that will watch a buffer for changes and execute different functions depending on the change.
I know I can use nvim_buf_attach() to subscribe to buffer events, but they are ...
1
vote
0
answers
82
views
Vim package development python support for 2, 3, or both?
Apparently there are some issues preventing vim from being built with both python and python3 support under many linux distributions and OSX. This makes it difficult or impossible for many users to ...
0
votes
1
answer
97
views
Generate non editable glyphs/adornments on top of text in Vim?
Visual Studio has a feature for C# that displays how many times a given method has been referenced. This information is displayed as tiny greyed out text above the method names. It is not possible to ...
16
votes
2
answers
3k
views
How to save and restore a mapping?
I am developing a plugin for Vim and I would like to define a mapping which would be available only while the "execution of the plugin".
So far the (simplified) workflow of the plugin is the ...