Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Required vim compiled with +python

Tags:

python

vim

When I typed in raw and hit <C-x><C-o> in a python file, I get the Error:Required vim compiled with +python. But according to the result of command :version, there is a + rather than - in front of python, what should I do to fix this problem?

+arabic          +cursorbind      -footer          +mksession       +path_extra      +startuptime     +visual
+autocmd         +cursorshape     +fork()          +modify_fname    -perl            +statusline      +visualextra
-balloon_eval    +dialog_con      +gettext         +mouse           +persistent_undo -sun_workshop    +viminfo
-browse          +diff            -hangul_input    -mouseshape      +postscript      +syntax          +vreplace
++builtin_terms  +digraphs        +iconv           +mouse_dec       +printer         +tag_binary      +wildignore
+byte_offset     -dnd             +insert_expand   -mouse_gpm       +profile         +tag_old_static  +wildmenu
+cindent         -ebcdic          +jumplist        -mouse_jsbterm   +python/dyn      -tag_any_white   +windows
+clientserver    +emacs_tags      +keymap          +mouse_netterm   +python3/dyn     -tcl             +writebackup
+clipboard       +eval            +langmap         +mouse_sgr       +quickfix        +terminfo        +X11
+cmdline_compl   +ex_extra        +libcall         -mouse_sysmouse  +reltime         +termresponse    +xfontset
+cmdline_hist    +extra_search    +linebreak       +mouse_urxvt     +rightleft       +textobjects     -xim
+cmdline_info    +farsi           +lispindent      +mouse_xterm     -ruby            +title           -xsmp
+comments        +file_in_path    +listcmds        +multi_byte      +scrollbind      -toolbar         +xterm_clipboard
+conceal         +find_in_path    +localmap        +multi_lang      +signs           +user_commands   -xterm_save
+cryptv          +float           -lua             -mzscheme        +smartindent     +vertsplit
+cscope          +folding         +menu            +netbeans_intg   -sniff           +virtualedit

Thanks

like image 872
Liangmin Li Avatar asked Oct 22 '25 10:10

Liangmin Li


1 Answers

Features marked as */dyn may or may not be available. The support for these features is not built in. It depends on the presence of dedicated shared objects.

To some of the features "/dyn" is added when the feature is only available when the related library can be dynamically loaded.

To check if your vim can use a dynamic feature, e.g. python do:

:echo has('python')

It will print 0 (false) or 1 (true)

See also python-dynamic.

Update:

If you installed vim from source, you will have to rebuild it. Use --enable-pythoninterp, --with-python-config-dir options. Also make sure you have python development headers and libraries installed (devel package).

like image 164
baf Avatar answered Oct 24 '25 01:10

baf



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!