-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vimrc
52 lines (44 loc) · 1.84 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
syntax on " enable syntax highlighting
set cursorline " highlight the current line
" set background=dark " darker color scheme
" set ruler " show line number in bar
set nobackup " don't create pointless backup files; Use VCS instead
set autoread " watch for file changes
set number " show line numbers
set showcmd " show selection metadata
set showmode " show INSERT, VISUAL, etc. mode
set showmatch " show matching brackets
set autoindent smartindent " auto/smart indent
set smarttab " better backspace and tab functionality
set scrolloff=5 " show at least 5 lines above/below
filetype on " enable filetype detection
filetype indent on " enable filetype-specific indenting
filetype plugin on " enable filetype-specific plugins
" colorscheme cobalt " requires cobalt.vim to be in ~/.vim/colors
" column-width visual indication
let &colorcolumn=join(range(81,999),",")
highlight ColorColumn ctermbg=235 guibg=#001D2F
" tabs and indenting
set autoindent " auto indenting
set smartindent " smart indenting
set expandtab " spaces instead of tabs
set tabstop=2 " 2 spaces for tabs
set shiftwidth=2 " 2 spaces for indentation
" bells
set noerrorbells " turn off audio bell
set visualbell " but leave on a visual bell
" search
set hlsearch " highlighted search results
set showmatch " show matching bracket
" other
set guioptions=aAace " don't show scrollbar in MacVim
" call pathogen#infect() " use pathogen
" clipboard
set clipboard=unnamed " allow yy, etc. to interact with OS X clipboard
" shortcuts
map <F2> :NERDTreeToggle<CR>
" remapped keys
inoremap { {}<Left>
inoremap {<CR> {<CR>}<Esc>O
inoremap {{ {
inoremap {} {}