-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc
99 lines (77 loc) · 1.96 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
""""""""""""""""""""""""""
" Turn off folding
"""""""""""""""""""""""""
noremap <S-j> j
noremap <S-k> k
"""""""""""""""""""""""""""""""""""""""""""""
" Environment + Visual Settings
"
"""""""""""""""""""""""""""""""""""""""""""""
syntax enable
set ruler
set number
" Set the highlighting on the Pmenu
highlight PMenu term=reverse cterm=bold ctermfg=white ctermbg=black
highlight PMenuSel term=reverse cterm=bold ctermfg=red ctermbg=black
"""""""""""""""""""""""""""""""""""""""""
" Basic Navigation and Text Manipulation
"
"""""""""""""""""""""""""""""""""""""""""
" Set the scroll offset to be 10 lines
set scrolloff=10
set backspace=indent,eol,start
" Map CTRL-L to go to the last line on the screen
map! <C-L> <ESC>Li
" Map CTRL-E to go to end of line
map! <C-e> <ESC>$a
" Map CTRL-A to go the start of line
map! <C-a> <ESC>^i
" Map CTRL-S to Write command
map! <C-s> <ESC>:wq
" Map CTRL-K to delete after the cursor
map! <C-k> <ESC>lDi
" Map CTRL-P to the go to toggle pastemode
" psych
" Map CTRL-] to tab right
map! <C-]> <ESC>>>i
map ; :
""""""""""""""""""""""""
" Global Indentation Rules
"
""""""""""""""""""""""""
set cindent
set autoindent
set tabstop=4
set shiftwidth=4
set cinkeys=0{,0},:,0#,!^F
"""""""""""""""""
" Paste Toggle
"""""""""""""""""
nnoremap <C-p> :set invpaste paste?<CR>
set pastetoggle=<C-p>
set showmode
"""""""""""""""""""""""""""
"" Surround plugings
""""""""""""""""""""""""""
noremap q' ysiw'
"nnoremap q\" ysiw\"
"nnoremap q] ysiw]
"nnoremap q) ysiw)
""""""""""""""""""""""
" Solarized
"""""""""""""""""""""
set background=dark
let g:solarized_termcolors=256
"colorscheme solarized
colorscheme monokai
"""""""""""""""""""""""
" Tagbars
""""""""""""""""""""""
imap <F8> <ESC>:TagbarToggle<CR>
nmap <F8> :TagbarToggle<CR>
""""""""""""""""""""""""""
" Turn off bell
"""""""""""""""""""""""""
set noerrorbells visualbell t_vb=
autocmd GUIEnter * set visualbell t_vb=
autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o