"++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"" "" __ _ _ _ __ ___ _ __ ___ "" \ \ / / | '_ ` _ \| '__/ __| "" \ V /| | | | | | | | | (__ "" \_/ |_|_| |_| |_|_| \___| "" "" ""++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"setlangmenu=en_US" set to English menulet $LANG='en_US'setnocompatible" use Vimfiletypeon" filetypefiletypepluginindenton"=====================================================""" Vim-plug settings"=====================================================callplug#begin('~/.vim/plugged')Plug'scrooloose/nerdtree'" nerdtreePlug'itchyny/lightline.vim'" status barPlug'tpope/vim-fugitive'" git pluginPlug'sheerun/vim-polyglot'" language supportPlug'mhinz/vim-startify'" start screenPlug'joshdick/onedark.vim'" color schemes"Plug 'flazz/vim-colorschemes'"Plug 'neoclide/coc.nvim', {'branch': 'release'}callplug#end()"====================================================="" General settings"=====================================================syntaxon" syntax highlightingsetbackground=darkcolorschemeonedark" color schemesettermguicolorssetcursorlinesetencoding=utf-8" file encodingsetnumber" show line numberssetrulersetttyfast" terminal accelerationsettabstop=4" 4 whitespaces for tabs visual presentationsetshiftwidth=4" shift lines by 4 spacessetsmarttab" set tabs for a shifttabs logicsetexpandtab" expand tabs into spacessetautoindentsmartindent" indent when moving to the next line while writing codesetshowmatch" shows matching part of bracket pairs (), [], {}setmatchpairs+=<:>" highlight match pairssetmagic" regular expressionsettitle" display titlesetnobackup" no backup filessetnowritebackup" only in case you don't want a backup file while editingsetnoswapfile" no swap filessetbackspace=indent,eol,start" fix common backspace problemssetnowrap" line wrapsethistory=1000" historysetautoread" reload files when changed on disk, i.e. via `git checkout`setshortmess=atIsetnoshowmodesetshowcmdsetselection=inclusivesetselectmode=mouse,keysetscrolloff=10" let 10 lines before/after cursor during scrollsetclipboard+=unnamed" use system clipboardsetlaststatus=2setexrc" enable usage of additional .vimrc files from working directorysetsecure" prohibit .vimrc files to execute shell, create files, etc...setpastetoggle=<C-p>" toggle paste mode"====================================================="" Search settings"=====================================================setincsearch" incremental searchsethlsearch" highlight search resultssetignorecase" ignore search casessetsmartcase" unless there is capital"====================================================="" Plugin settings"=====================================================letg:lightline= { \ 'colorscheme': 'onedark', \ }" Some key remappingmap<C-n> :NERDTreeToggle<CR>"====================================================="" Keybindings"=====================================================inoremap<C-a><Home>inoremap<C-e><End>inoremap<C-v><ESC>"+pa" Quick Esc inoremapjj<Esc>inoremapjk<Esc>" Easy window navigationnnoremap<C-J><C-W>jnnoremap<C-K><C-W>knnoremap<C-L><C-W>lnnoremap<C-H><C-W>h" Quick yanking to the end of the linennoremapYy$" Jump to matching pairs easily, with Tabnnoremap<Tab> %vnoremap<Tab> %" Foldingnnoremap<Space>zavnoremap<Space>za" Map ; to : and save a million keystrokes" ex mode commands made easy 用于快速进入命令行nnoremap ; :" Shift+H goto head of the line, Shift+L goto end of the linennoremapH ^nnoremapL $" Tabnnoremap<C-Left> :tabprevious<CR>nnoremap<C-Right> :tabnext<CR>" Auto indent pasted text"nnoremap p p=`]<C-o>"nnoremap P P=`]<C-o>