2012年3月21日星期三

(Vim + Pydiction + Pydoc)/Windows

  1. Download + install gvim。
  2. :ec $HOME
  3. mkdir $HOME\vimfiles
  4. Download Pydiction, unzip, copy file "python_pydiction.vim" to "$HOME\vimfiles\ftplugin"。
  5. Download pydoc.vim, rename file "pydoc.vim" to "python_pydoc.vim" and copy to "$HOME\vimfiles\ftplugin"。
  6. Edit "$HOME/_vimrc"如下。
  7. To check plugin loaded, type :script
  8. To auto-complete in insert mode, Ctrl-X-Ctrl-N
  9. To get Python os module document, type :Pydoc os

set lines=55 columns=100
set autoindent
set smartindent
set tabstop=4
set shiftwidth=4
set number
hi normal   ctermfg=white  ctermbg=black guifg=white  guibg=black
hi nontext  ctermfg=blue   ctermbg=black guifg=blue   guibg=black
filetype plugin on
syntax on
let g:pydiction_location = 'C:/vimfiles/pydiction/complete-dict'
let g:pydoc_cmd = 'C:/python27/python -m pydoc'


沒有留言:

發佈留言