Bigzhu's den

vim python 配置

bigzhu

python-mode 各种问题

语法检查

https://github.com/w0rp/ale

屏蔽一些报错

let g:ale_python_flake8_options = "--ignor='E501'"

代码格式化

sudo pip install yapf

加入配置:

:0,$!yapf<CR>

import 整理

sudo pip install isort

跳转到函数定义

”‘bash git clone –recursive https://github.com/davidhalter/jedi-vim.git ~/.vim/bundle/jedi-vim “’

  • 自动补全和重构名称之类, 都可以用这个

”’ Completion Goto assignments g (typical goto function) Goto definitions d (follow identifier as far as possible, includes imports and statements) Show Documentation/Pydoc K (shows a popup with assignments) Renaming r Usages n (shows all the usages of a name) Open module, e.g. :Pyimport os (opens the os module) “’

bigzhu
Everything is learnable