-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvimrc_NORMAL_USER
48 lines (42 loc) · 1.07 KB
/
vimrc_NORMAL_USER
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
" show line numbers
:set number
" 1 tab = 4 spaces
:set tabstop=4
" when indent 4 spaces will be used
:set shiftwidth=4
" indicate where the column 80 resides
set colorcolumn=80
highlight ColorColumn ctermbg=lightgray
" auto read when a file is changed from the outside
:set autoread
:set autowrite
" Syntax Highlighting
if has("syntax")
syntax on
endif
" show matching bracket
:set showmatch
:set autoindent
:set smartindent
" stricter rules for c programs
:set cindent
" always show the status line
:set laststatus=2
" Format the status line
set statusline=\ %m%r\ Line:\ %l\ \ Column:\ %c
set statusline+=%=
set statusline+=\ \ CWD:\ %<%{getcwd()}/%f
set statusline+=\ \
" Delete trailing white space on save, useful for some filetypes ;)
"fun! CleanExtraSpaces()
" let save_cursor = getpos(".")
" let old_query = getreg('/')
" silent! %s/\s\+$//e
" call setpos('.', save_cursor)
" call setreg('/', old_query)
"endfun
" Avoid garbled characters in Chinese language windows OS
let $LANG='en'
set langmenu=en
source $VIMRUNTIME/delmenu.vim
source $VIMRUNTIME/menu.vim