DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’» is a community of 963,673 amazing developers

We're a place where coders share, stay up-to-date and grow their careers.

Create account Log in
Yao-Ching Huang
Yao-Ching Huang

Posted on • Updated on

IDE :: Compiling Vim with Python3 support

Prerequisites

  • Python3
  • make
  • libtool

Confirm the Python path and version

$ which python3
/Users/tom/.pyenv/shims/python3

$ python3 -V
Python 3.10.6
Enter fullscreen mode Exit fullscreen mode

Compile Vim with Python3 support

git clone https://github.com/vim/vim.git
cd vim/src
./configure --enable-python3interp
make
sudo make install
Enter fullscreen mode Exit fullscreen mode

Validation

Running :py3 import sys;print(sys.version); in Vim will show the linked Python version.

3.10.6 (main, Aug  8 2022, 15:10:42) [Clang 13.1.6 (clang-1316.0.21.2.5)]
Enter fullscreen mode Exit fullscreen mode

See also

https://github.com/vim/vim/blob/master/src/INSTALL

https://github.com/vim/vim/blob/master/src/Makefile

Top comments (0)

Take a look at this:

Settings

Go to your customization settings to nudge your home feed to show content more relevant to your developer experience level. πŸ›