Some new vim tricks

This commit is contained in:
madmaurice 2015-07-10 17:49:49 +02:00
parent c1884475b3
commit 98e580f814

24
vimrc
View file

@ -3,6 +3,8 @@ set nocompatible
" CL History
set history=700
set modelines=0
"Enable filetype plugins
filetype plugin on
filetype indent on
@ -15,11 +17,15 @@ set wildmenu
set wildignore=*.o,*~,*.pyc
set gdefault
set noruler
set laststatus=2
"set cmdheight=2
set number
set hid
set backspace=eol,start,indent
@ -72,10 +78,22 @@ set ai "auto indent
set si "smart indent
set wrap "wrap lines
set number
let mapleader = ","
" Make double-<Esc> clear search highlights
nnoremap <silent> <Esc><Esc> :nohlsearch<CR>
" nnoremap <silent> <Esc><Esc> :nohlsearch<CR>
nnoremap <silent> <leader><space> :noh<cr>
inoremap <F1> <nop>
nnoremap <F1> <nop>
vnoremap <F1> <nop>
nnoremap q <nop>
nnoremap / /\v
vnoremap / /\v
nnoremap <leader>w <C-w>v<C-w>l
set whichwrap+=<,>,[,]
@ -85,7 +103,7 @@ nnoremap U <c-r>
highlight WhitespaceEOL ctermbg=Red guibg=Red
match WhitespaceEOL /\s\+$/
nnoremap <silent> <F5> :normal gg=G<CR>
nnoremap <silent> <leader>f :normal gg=G<CR>
set statusline=%m
set statusline+=\ %f