-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvimrc.local
67 lines (39 loc) · 1.56 KB
/
vimrc.local
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
"====[ Disable code folding ]==============================
set nofoldenable
"====[ Yanks to go clipboard instead ]=====================
set nowrap
set textwidth=0
"====[ Make the 81st column stand out ]====================
set colorcolumn=81
"====[ Default color scheme set to solarized ]=============
set background=dark
if has('gui_running') || $TERM =~ "256color"
let g:solarized_termcolors=256
else
let g:solarized_termcolors=16
endif
colorscheme solarized " Set colorscheme
"====[ Swap : and ; to make colon commands easier to type ]
nnoremap ; :
"====[ Undo settings ]===================================
set undodir=~/.vimundo
set undofile
set undolevels=1000 "max number of changes that can be undone
set undoreload=10000 "max number lines to save for undo on a buffer reload
"====[ Read a file that is modified from outside ]========
set autoread
"====[ Fast saving ]======================================
nmap <leader>w :w!<cr>
"====[ Toggle paste mode ]================================
map <leader>pp :setlocal paste!<cr>
"====[ Linebreak on 500 characters ]======================
set lbr
set tw=500
"====[ Auto indent ]======================================
set ai "Auto indent
"====[ Wrap lines ]========================================
set wrap "Wrap lines"
"====[ Save files as sudo with :w!! ]======================
cmap w!! w !sudo tee > /dev/null %
"====[ Disable double escape to insert mode ]======================
inoremap <expr> <Esc> "<Esc>"