I was not able to deal with it after a long time. I was so upset that I made a military order in an angry manner. So I got it...
Write down the configuration process: (my system Debian 3.1, vim7, python2.4)
[1] Download vim7 source package (http://www.vim.org), SJTU source inside it seems there is no vim7.
[2] Compilation:
./Configure -- enable-pythoninterp
Make
Make install
[3] In Your ~ /. Add filetype plugin on to vimrc and check whether the file is ready:
Run the following command to create a py file:
Import OS
OS. {^ x ^ O}
Can I see if auto-completion is available? If a bunch of errors are prompted, congratulations. Let's take a look at the solution below.
If it is automatically completed, it will end here, BS me.
[4] vim7: version. Check whether the feature contains + python. If it is-Python, you have not enabled vim7's support for python and need to re-compile it:
./Configure -- enable-pythoninterp -- With-Python-config-Dir =/usr/lib/python2.4/config/
Make
Make install
Note the/usr/lib/python2.4/config/directory. If you do not have this directory, you do not have the python-dev package (not the python running package ), apt-Get.
Then pay close attention to the configure process and check for any errors.
[5] This Time: For version, you should see + python. If it is still-Python, check whether errors have occurred in step [4.
At the same time, there are still many minor issues to pay attention to during the installation process. I will not detail them here. I believe you can solve them by Google.
Finally don't forget to carefully read the introduction of pythoncomplete (http://www.vim.org/scripts/script.php? Script_id = 1542)
After the last one is done, hey