From 42b26a34889bf150f677ef6584d81509fa776339 Mon Sep 17 00:00:00 2001 From: ache Date: Thu, 22 Feb 2018 14:24:54 +0100 Subject: [BIG] Clean up the config --- plugin/perso.vim | 94 ++++++++++++++++++++------------------------------------ 1 file changed, 34 insertions(+), 60 deletions(-) (limited to 'plugin/perso.vim') diff --git a/plugin/perso.vim b/plugin/perso.vim index 11b4ed1..9af12b0 100755 --- a/plugin/perso.vim +++ b/plugin/perso.vim @@ -9,45 +9,24 @@ set t_Co=256 "map k k "map h h "map l l +filetype plugin indent on - - - -set encoding=utf-8 -set fileencoding=utf-8 - - +" Color : +colo jellybeans +set cursorline hi CursorLine term=bold cterm=bold ctermbg=black - - - -filetype plugin indent on - +" Completion related options +" wildcard char = +set wildmenu +set wildmode=list:longest:full nnoremap :set pastem`o``:set nopaste nnoremap :set pastem`O``:set nopaste - inoremap A inoremap 0i - -"inoremap { {}$ -"inoremap {{ { -"inoremap {} {} -"inoremap << <> -"inoremap [ [] -"inoremap [[ [ -"inoremap [] [] -"inoremap ( () -"inoremap (( ( -"inoremap () () -"inoremap " "" -"inoremap "" "" -"inoremap ' '' -"inoremap '' '' - "Perso C définition" inoremap prt printf inoremap swf printf @@ -63,41 +42,43 @@ inoremap #io #include inoremap #main int main(void) {}A inoremap ##main int main(int argc, char* argv[]) {}A - - - - " Personal shortcurts -" Copy clip -nnoremap èè__ :set pastemn"+p'n:set nopaste -" Select clip -nnoremap èèè_ :set pastemn"*p'n:set nopaste -nmap :TagbarToggle - ca tn tabnew ca tc tabc +map :setlocal spell! spelllang=fr +map :setlocal spell! spelllang=en_us +inoremap =strftime('%F') +inoremap =strftime('%c') + + +" Personal compil shortcurts +map :make:cw +noremap [q :copen +noremap ]q :cclose +noremap [Q :cfirst +noremap ]Q :clast +noremap [[ :cprev +noremap ]] :cnext + "Allow vim clipboad <-> host clipboard to share data set clipboard=unnamed - " Quick Comment : -autocmd FileType c,cpp,java,go,scala let b:comment_leader = '//' -autocmd FileType sh,ruby,python let b:comment_leader = '#' -autocmd FileType conf,fstab let b:comment_leader = '#' -autocmd FileType tex let b:comment_leader = '%' -autocmd FileType mail let b:comment_leader = '>' -autocmd FileType vim let b:comment_leader = '"' -autocmd FileType haskell let b:comment_leader = '--' - +autocmd FileType c,cpp,java,go,scala,js let b:comment_leader = '//' +autocmd FileType sh,ruby,python let b:comment_leader = '#' +autocmd FileType conf,fstab let b:comment_leader = '#' +autocmd FileType tex let b:comment_leader = '%' +autocmd FileType mail let b:comment_leader = '>' +autocmd FileType vim let b:comment_leader = '"' +autocmd FileType haskell let b:comment_leader = '--' autocmd FileType c,cpp,java,go,scala set foldmethod=syntax - noremap ,cc :silent s/^/=escape(b:comment_leader,'\/')/:nohlsearch noremap ,cu :silent s/^\V=escape(b:comment_leader,'\/')//e:nohlsearch @@ -108,19 +89,10 @@ noremap c :silent s/^\V=escape(b:comment_leade nnoremap cd :cd %:p:h nnoremap // :nohls -map :setlocal spell! spelllang=fr -map :setlocal spell! spelllang=en_us -inoremap =strftime('%F') -inoremap =strftime('%c') -map :make:cw -noremap [q :copen -noremap ]q :cclose -noremap [Q :cfirst -noremap ]Q :clast -noremap [[ :cprev -noremap ]] :cnext + +" Compil option autocmd Filetype c call SetCCompiler() function SetCCompiler() if !(filereadable("makefile") || filereadable("Makefile")) @@ -143,6 +115,8 @@ noremap zv :!markdown % \| w3m -I utf-8 -T text/html + + set colorcolumn=80 set cursorcolumn highlight CursorColumn ctermbg=Red -- cgit v1.2.3