-
Notifications
You must be signed in to change notification settings - Fork 7
/
vimrc
46 lines (39 loc) · 1.06 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
" Section: load OS init scripts
if has("win64") || has("win32")
source $HOME\\vimfiles\\init\\win.vim
elseif has("mac") || has("unix")
source $HOME/.vim/init/unix.vim
source $HOME/.vim/init/mac.vim
elseif has("unix")
source $HOME/.vim/init/unix.vim
endif
" Section: load defaults config
if filereadable(expand("$VIMRUNTIME/defaults.vim"))
source $VIMRUNTIME/defaults.vim
endif
" Section: GUI setup
autocmd GUIEnter * set guioptions-=r guioptions-=L
" Section: Edit: indent, tab, space
setglobal shiftround
setglobal smarttab
setglobal tabstop=8
setglobal softtabstop=0
setglobal shiftwidth=8
setglobal expandtab
setglobal autoindent
setglobal cindent
setglobal hidden
setglobal belloff=all
" setglobal number
" Section: move arround quickly
" map space for ctrl-d page down.
nmap <Space> <C-D>
let mapleader = ","
nmap <Leader>ew :e <C-r>=expand('%:h')<CR>
nmap <Leader>ee :e <C-r>=expand('#')<CR><CR>
nmap <Leader>wv :vsplit<CR>
nmap <Leader>wh :split<CR>
nmap <Leader>ww <C-W>o
let g:netrw_list_hide='.*\.swp$'
" let g:netrw_hide=1
" vim:set et sw=2 foldmethod=expr