看前面的帖子,安装coc
然后vimrc中添加这段
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" " => python settings """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" ""------F5 run python-file------ map <F5> :call CompileRunGcc()<CR> func! CompileRunGcc() exec "w" if &filetype == 'python' exec "!python %" endif endfunc "------End------ let python_highlight_all=1 autocmd Filetype python set tabstop=4 autocmd Filetype python set softtabstop=4 autocmd Filetype python set shiftwidth=4 autocmd Filetype python set textwidth=79 autocmd Filetype python set expandtab autocmd Filetype python set autoindent autocmd Filetype python set fileformat=unix autocmd Filetype python set foldmethod=indent autocmd Filetype python set foldlevel=99 set updatetime=100
按下f5键就可以运行python啦
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。