3

I decided to write a plugin for vim. I want to write it mainly in python, as I am most proficient in it. I started development with this example: http://brainacle.com/how-to-write-vim-plugins-with-python.html

But the problem I have - I want to use some non-standard library modules and I wonder - how should I add them? My guess is that vim uses it's own python that is compiled in it, therefore I cannot really use pip to install these modules. Should I just provide the modules I want to use within the plugin itself?

2
  • It would depend on the module. Is is widely packaged, or a more obscure module? Is it one file? Or a lot of files? Is the license compatible with your project's license? Jun 1, 2015 at 10:46
  • 1
    >My guess is that vim uses it's own python that is compiled in it, therefore I cannot really use pip to install these modules. Vim may use dynamic linked python more then one version. See he: python-2-and-3 Of course I can build vim myself with any version of python (py2 or py3) or with both of them.
    – Alex Kroll
    Jun 1, 2015 at 14:06

1 Answer 1

2

Should I just provide the modules I want to use within the plugin itself?

Yes: if your main concern is portability, this is likely to be your best bet.

Edit: Please explain the downvotes?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.