The python I want to use is located at C:\randomplace\python.

I have a dev machine that has multiple instances of python (so relying on finding python in$PATH is unreliable).

How do I configure vim to use just the before mentioned for the purpose of vim plugins etc?


Add the following to your vimrc:

set pythonhome=C:\randomplace\python
set pythondll=C:\randomplace\python\python27.dll

For python3 use pythonthreehome and pythonthreedll.

For this to work python dynamic support must be compiled in. The following command must print 1:

:echo has("python_dynamic")

For python3:

:echo has("python3_dynamic")

See :help python-dynamic and help for the named options.

This site is temporarily in read only mode and not accepting new answers.

Not the answer you're looking for? Browse other questions tagged .