RawIron / devops-my-ubuntu

clone my ubuntu setup using Ansible playbook
1 stars 1 forks source link

vim - configure python ide #22

Closed RawIron closed 7 years ago

RawIron commented 8 years ago

code completion (IntelliSense) and navigation

for any code completion in vim to work the omnicomplete feature is needed. omnicomplete is available since vim 7.

filetype plugin on
set omnifunc=syntaxcomplete#Complete

Python

different options for python are available. all of them need vim to be compiled with the pythoninterp. check vim for +python or +python3:

vim --version
sudo apt-get install python3-pip
pip3 install future frozendict

git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
vim +PluginInstall +qall
cd ~/.vim/bundle/YouCompleteMe
git submodule update --init --recursive

sudo apt-get install cmake
cd ~/.vim/bundle/YouCompleteMe
./install.py --clang-completer

ctags

install exuberant-ctags

apt-get install exuberant-ctags

navigate ctags with tagbar

enable exuberant-ctags

let g:tagbar_ctags_bin = '/usr/bin/ctags-exuberant'

project view

source-code browser NerdTree

snippets

for code snippets UltiSnips is great.

syntax highlighting

syntax on

check syntax and inspect

use syntastic

run and test

:make