Author: Cao (ck89119) Kai [email protected] inspired by vgod https://github.com/vgod/vimrc
Use curl:
curl -o - https://raw.github.com/ck89119/.vim/master/auto-install.sh | sh
or wget:
wget -O - https://raw.github.com/ck89119/.vim/master/auto-install.sh | sh
-
Check out from github
git clone git://github.com/ck89119/.vim.git ~/.vim cd ~/.vim git submodule update --init --recursive
-
Install YCM
cd bundle/YouCompleteMe sudo apt-get install build-essential cmake sudo apt-get install python-dev ./install.py --clang-completer
-
Install ~/.vimrc
cd ~/.vim ./install-vimrc.sh
All plugins were checked out as git submodules,
which can be upgraded with git pull
. For example, to upgrade easymotion
cd ~/.vim/bundle/easymotion
git pull
To install a new plugin as a git submoudle, type the following commands.
cd ~/.vim
git submodule add [GIT-REPOSITORY-URL] bundle/[PLUGIN-NAME]
-
Pathogen: Pathogen let us install a plugin as a bundle in ~/.vim/bundle seprately.
-
NerdTree: A tree explorer plugin for navigating the filesystem.
Useful commands:
:Bookmark [name]
bookmark any directory as name
:NERDTree [name]
open the bookmark [name] in Nerd Tree
F6
toggle the NerdTree -
nerdcommenter: Easy to (un)comment code.
Useful commands:
,cc
comment out the current line or text selected in visual mode
,cu
uncomments the selected line(s) -
YouCompleteMe: A code-completion engine for Vim.
-
UltiSnips: The ultimate snippet solution for Vim.
Useful commands:
F9
active related snippet -
vim-surround: Deal with pairs of surroundings.
Useful commands:
cs"'
inside"Hello world!"
, then"Hello world!"
=>'Hello world!'
-
EasyMotion: An easy way to jump to a word.
Useful commands:
,,w
forward EasyMotion
,,b
backward EasyMotion -
TagBar: browsing the tags of source files ordered by classes.
Useful commands:
F7
toggle the TagBar