-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.vimrc
67 lines (56 loc) · 1.78 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
let mapleader = ","
inoremap <C-\> <ESC>
command! W write
command! Q q
command! Qa qa
command! Wa wa
set guifont=AnonymousRegular:h18
set colorcolumn=100
set noerrorbells visualbell t_vb=
autocmd GUIEnter * set visualbell t_vb=
" Use Vim settings, rather than Vi settings (much better!).
" This must be first, because it changes other options as a side effect.
set nocompatible
" allow backspacing over everything in insert mode
set backspace=indent,eol,start
set nobackup
set noswapfile
set nowritebackup
set history=1000 " keep 100 lines of command line history
set ruler " show the cursor position all the time
set showcmd " display incomplete commands
set incsearch " do incremental searching
" Don't use Ex mode, use Q for formatting
map Q gq
" CTRL-U in insert mode deletes a lot. Use CTRL-G u to first break undo,
" so that you can undo CTRL-U after inserting a line break.
inoremap <C-U> <C-G>u<C-U>
" In many terminal emulators the mouse works just fine, thus enable it.
if has('mouse')
set mouse=a
endif
" Switch syntax highlighting on, when the terminal has colors
" Also switch on highlighting the last used search pattern.
if &t_Co > 2 || has("gui_running")
syntax on
set hlsearch
endif
set autoindent " always set autoindenting on
set nosmartindent
set tabstop=2
set shiftwidth=2
set expandtab
set number
highlight LineNr ctermfg=black ctermbg=grey
" Convenient command to see the difference between the current buffer and the
" file it was loaded from, thus the changes you made.
" Only define it when not defined already.
if !exists(":DiffOrig")
command DiffOrig vert new | set bt=nofile | r ++edit # | 0d_ | diffthis
\ | wincmd p | diffthis
endif
filetype plugin indent on
set background=dark
" Enable in some odd environments where theme is not working
" t_CO=256
colorscheme one