-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc
66 lines (58 loc) · 1.4 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
"
" Install plugins:
"
" :PluginInstall
"
set nocp
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Plugin 'VundleVim/Vundle.vim'
Bundle 'tpope/vim-fugitive'
Bundle 'christoomey/vim-tmux-navigator'
Bundle 'mileszs/ack.vim'
Bundle 'kien/ctrlp.vim'
Bundle 'vim-airline/vim-airline'
Bundle 'tomtom/tcomment_vim'
Bundle 'rhysd/vim-grammarous'
Bundle 'scrooloose/nerdtree'
call vundle#end()
filet plugin indent on
syn on
set bg=dark
set hls sta nonu ai si nobk nowb noswf tf nolz
set backspace=indent,eol,start
set ts=2 sw=2 sts=2 et ls=2
set encoding=utf-8
set clipboard=unnamed
set ttyfast
set ttyscroll=3
set lazyredraw
set nocursorcolumn
set nocursorline
set t_ut=
set t_Co=256
set grepprg=ag\ --vimgrep
set grepformat=%f:%l:%c%m
set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*.gz,*.tar
" Make unwanted characters visible
"
" set list lcs=tab:·⁖,trail:¶
" or
" set list lcs=tab:»·,trail:·
" Set the ack tool
let g:ackprg = 'ag --nogroup --nocolor --column'
" Spell Check
au FileType markdown setlocal spell
" Remove trailing whitespace on write
au FileType ruby,eruby,go,javascript,yaml,python,php,c,cpp,css,java autocmd BufWritePre <buffer> :%s/\s\+$//e
" Mappings
" -> Buffer nav
map <C-Tab> :bn<CR>
map <C-S-Tab> :bp<CR>
" -> Nerdtree
map <C-n> :NERDTreeToggle<CR>
" Search for the string under cursor using :Ack
vnoremap <F3> :Ack <C-R><C-W> *<CR>
" -> Quickfix nav
map <C-S-J> :cn<CR>
map <C-S-K> :cp<CR>