-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vimrc
52 lines (40 loc) · 886 Bytes
/
.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
" Use UTF-8 by default
set encoding=utf8
" Enable syntax coloring
syntax on
" Enable line numbers
set nu
" Enable auto refresh file when changed from outside
set autoread
" Quick sudo-save with :W
command W w !sudo tee % > /dev/null
" Always show cursor position
set ruler
" Better search - ignore case, be smart about case,
" highlight search results
set ignorecase
set smartcase
set hlsearch
" Show matching brackets
set showmatch
" Disable autobackups
set nobackup
set nowb
set noswapfile
" Modern indentation - spaces instead of tabs
set expandtab
set smarttab
" One indentation == 4 spaces
set shiftwidth=4
set tabstop=4
" Automagically try to be smart about indenting
set ai
set si
" Auto-close parentheses and brackets
" Escape with CTRL-V when you need a single char.
ino " ""<left>
ino ' ''<left>
ino ( ()<left>
ino [ []<left>
ino { {}<left>
ino {<CR> {<CR>}<ESC>O