Saturday, January 7, 2012

New to Vim

Even though I used vi a lot before, I am not quite sure the color scheme and how it can help program. I learned a little bit:

First note that the .vimrc file is very import, it is the configuration of vim and also macVim. It is at ~/. Thus you can use vim ~/.vimrc to open it. ~/.vim is a directory, which is the place to store some plugins. Don't confuse them.

1 Color scheme
There are lots of schemes you can download from web, and they can make your vim more personalized. You simply download the .vim color scheme file and move it to ~/.vim/color. Then apply it in .vimrc. Details is in:
http://ajayfromiiit.wordpress.com/2006/06/24/installing-color-schemes-for-vim-editor/
There is a package which contains hundreds of schemes, link is:
http://www.vim.org/scripts/script.php?script_id=625

2 Add some plugins into vim
The pattern for doing it normally like this: (1) Add some plug in files (.vim) into ~/.vim/plugin (2) Add some statements in .vimrc
Two links below are a good reference. They implement an IDE for python under vim.
http://blog.dispatched.ch/2009/05/24/vim-as-python-ide/
http://www.cnblogs.com/samwei/archive/2011/04/25/2026211.htm

No comments:

Post a Comment