Pro Yearly is on sale from $80 to $50! »

Vim as a Python IDE

Vim as a Python IDE

Describes how to install and configure Vim so that normal human beings can use it effectively as a fully fledged Python IDE. The github repository mentioned on the last slide contains a fresh .vimrc file for beginners that will turn your Vim into a beautiful IDE within 10 minutes.

Presented at PyCon APAC 2012, Singapore
Video: https://www.youtube.com/watch?v=YhqsjUUHj6g
Github: https://github.com/mbrochh/vim-as-a-python-ide

3949eadbf8213b05e415415b2c17eaee?s=128

Martin Brochhaus

June 11, 2012
Tweet

Transcript

  1. VIM AS A PYTHON IDE It’s much easier than you

    think Martin Brochhaus (@mbrochh) PyCon APAC 2012 Saturday, June 9, 12
  2. WHERE DO I COME FROM? 1982 1994 1996 2003 2005

    2008 2011 Amiga Basic Win 95 PHP Dreamweaver Win XP JAVA Eclipse Win XP C# Visual Studio Ubuntu Python Wing IDE Ubuntu Python Vim Saturday, June 9, 12
  3. • Cross platform • Standard on most systems • Very

    fast • It’s good for your health (HJKL movement) • Highly customizable • Great for pair programming • Work anywhere, anytime • Change jobs, keep tools WHY SHOULD YOU CARE? Saturday, June 9, 12
  4. WHAT MAKES AN IDE? • Fast access to all files

    • Color scheme • Syntax highlighting • Static code analysis • Code completion • Go to definition • Refactoring • Debugging Saturday, June 9, 12
  5. TOPICS 1. How to install Vim 2. Your first .vimrc

    3. Install your plugins 4. Pair Programming Saturday, June 9, 12
  6. 1. HOW TO INSTALL VIM # Prerequisites: # (Ubuntu) sudo

    apt-get build-dep vim # (OSX) Command Line Tools for Xcode $ hg clone https://vim.googlecode.com/hg/ vim $ cd vim/src $ ./configure --enable-pythoninterp --with-features=huge --prefix=$HOME/opt/vim $ make && make install $ mkdir -p $HOME/bin $ cd $HOME/bin $ ln -s $HOME/opt/vim/bin/vim $ which vim $ vim --version # on Ubuntu: $ sudo apt-get install gtk2-engines-pixbuf Saturday, June 9, 12
  7. 2. YOUR FIRST .VIMRC • Start from scratch • Get

    inspired: vimbits.com • Steal whatever you need • Ask others (#vim) • save your .vimrc on GitHub Saturday, June 9, 12
  8. 3. INSTALL YOUR PLUGINS • vim-powerline (https://github.com/Lokaltog/vim-powerline) • python-mode (https://github.com/klen/python-mode)

    • ctrlp.vim (https://github.com/kien/ctrlp.vim) • python_editing (http://www.vim.org/scripts/script.php?script_id=1494) Saturday, June 9, 12
  9. 4. PAIR PROGRAMMING http://martinbrochhaus.com/2012/05/pair.html Saturday, June 9, 12

  10. THANK YOU (https://github.com/mbrochh/vim-as-a-python-ide) @mbrochh Saturday, June 9, 12