forked from jmelis/system-bootstrap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vimrc
69 lines (52 loc) · 1.12 KB
/
.vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
syntax on
set ts=4
set sw=4
set sts=4
set et
set ai
set hlsearch
set bg=dark
"set ic
set hidden
" Press F4 to toggle highlighting on/off, and show current value.
noremap <F4> :set hlsearch! hlsearch?<CR>
noremap <F12> @@<CR>
let mapleader = ","
map <leader>d :execute 'NERDTreeToggle ' . getcwd()<CR>
map <F9> <ESC>:tabprevious<CR>
map <F10> <ESC>:tabnext<CR>
map! <F9> <ESC>:tabprevious<CR>
map! <F10> <ESC>:tabnext<CR>
"inoremap <up> g<up>
"inoremap <down> g<down>
map <m-left> <ESC>:tabprevious<CR>
map <m-right> <ESC>:tabnext<CR>
map! <m-left> <ESC>:tabprevious<CR>
map! <m-right> <ESC>:tabnext<CR>
map <C-s> :w<CR>
cabbr te tabedit
cabbr ff FufFile
" highlight ExtraWhitespace ctermbg=red guibg=red
" match ExtraWhitespace /\s\+$/
" match ErrorMsg '\%>80v.\+'
" NERDTree
let NERDTreeShowBookmarks=1
nnoremap j gj
nnoremap k gk
nnoremap n nzz
nnoremap N Nzz
nnoremap * *zz
nnoremap # #zz
nnoremap g* g*zz
nnoremap g# g#zz
" Remember last position
function! ResCur()
if line("'\"") <= line("$")
normal! g`"
return 1
endif
endfunction
augroup resCur
autocmd!
autocmd BufWinEnter * call ResCur()
augroup END