This is a vim config files managed by pathogen.After download the project, you should take a minute to know how pathogen
click me works.
Features:
- Some plugins which are used very often.
- An easy way of extension, you can add anything as an submodule.
- Easy to install and update: you need only one command.
- Easy to compile and debug program: you need not exit your vim any more.
This is syntax hight for go language. You need not do nothing to invoke it.
With this plugin, you can brow your file in one project more easily: it will be displayed in file tree.
config
let g:nerdtree_tabs_open_on_console_startup=0
let g:pydiction_location = '~/.vim/bundle/pydiction/complete-dict'
map <leader>n <plug>NERDTreeTabsToggle <CR>
invoke
To invoke it , just put `\n` in vim NORMAL mode.
config
autocmd FileType python,shell set commentstring=#\ %s " 设置Python注释字符
autocmd FileType mako set cms=##\ %s
nmap ,c gcc
nmap ,u gcu
invoke
Select what you want to comment in visual mode. Then use gcc
or gcu
.
(to be added)
(to be added)
With this plugin, you can management much easier.
config filetype plugin indent on runtime bundle/vim-pathogen/autoload/pathogen.vim call pathogen#infect() invoke Do nothing.
ignore
(to be added)
(to be added)
(to be added)
This is just for syntax hightlight for markdown.
(to be added)
This is for search PinYin. config
vim-PinyinSearch
let g:PinyinSearch_Dict = '/home/huangyk/.vim/bundle/vim-PinyinSearch/PinyinSearch.dict'
map ? :call PinyinSearch()<cr>
invoke
Just input ?
in NORMAL model.
This is usefull when you want to display some info about the pwd, model, filename, encode, and so on. config
"airline
if !exists('g:airline_symbols')
let g:airline_symbols = {}
endif
let g:airline_left_sep = '>'
let g:airline_right_sep = '<'
let g:airline_section_b = '%{getcwd()}'
let g:airline#extensions#tabline#enabled = 1
let g:airline#extensions#tabline#left_sep = ' '
let g:airline#extensions#tabline#left_alt_sep = '|'
" set the status line
set laststatus=2
invoke Do nothing.
When there are many files in your project, chances are that you want to open the files which were opened recently.This plugin helps you to do this.
config "ctrlp let g:ctrlp_map = '' let g:ctrlp_cmd = 'CtrlP'
invode
Input <c-p>
in NORMAL model.
In some IDE like Visual Studio or Eclipse, we can see the name of typedef,Class, Function and so on.This plugin can help you do this. config
"taglist 设置
let Tlist_Show_One_File=1
let Tlist_Exit_OnlyWindow=1
let Tlist_Ctags_Cmd="/usr/bin/ctags"
map tl :Tlist<cr>
invode
Input tl
in NORMAL model.
This plugin will help you manage the windows in one terminal. config
"winManager config
let g:winManagerWindowLayout='FileExplorer|TagList'
map wm :WMToggle<cr>
let g:AutoOpenWinManager = 1
invoke
Input wm
in VIM NORMAL model.
This plugin will help you use tag more quickly.
You can find
- where the function is defined?
- where the function is called?
- which function is called by the function?
config
"cscope
map cs ":cscope -Rbq<cr>"
set cscopequickfix=s-,c-,d-,i-,t-,e-
"nmap<C-_>s :cs find s<C-R>=expand("<cword>")<CR><CR>)
" s: Find this C symbol
" nnoremap <leader>fs :call cscope#find('s', expand('<cword>'))<CR>
" g: Find this definition
nnoremap ,fg :call cscope#find('g', expand('<cword>'))<CR><CR>
" d: Find functions called by this function
nnoremap ,fd :call cscope#find('d', expand('<cword>'))<CR><CR>
" c: Find functions calling this function
invoke
As you see in the config above, you can call it by ,fg
or ,fc
.
When you use visual studio
, you can use F7
to compile and F5
to debug. Now you can also do this with our vimrc.
Usage
You can find this by "map key" in vimrc.
git clone https://github.com/huangyukun2012/vimconfig.git
./install
How to install new plugin
-
Download a plugin from github in to directory of
bundle
git clone $URL $PATH
-
Add this plugin as an submodule to your project
You can use git command to do this:
git submodule add $URL $PATH
-
Add the modification to the project, commit , and push it to your repository.
git add $PATH git commit -m $MSG git push origin master