-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathvimrc
109 lines (91 loc) · 2.52 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
set nocompatible
set number
set incsearch
set hlsearch
map <C-j> <C-W>j
map <C-k> <C-W>k
map <C-h> <C-W>h
map <C-l> <C-W>l
" editing options
set tabstop=2
set shiftwidth=2
set softtabstop=2
set expandtab
set smarttab
set backspace=indent,eol,start
let g:airline_powerline_fonts = 1
call plug#begin('~/.vim/plugged')
Plug 'bling/vim-airline'
Plug 'tpope/vim-fugitive'
Plug 'tpope/vim-endwise'
Plug 'ntpeters/vim-better-whitespace'
Plug 'slim-template/vim-slim'
Plug 'airblade/vim-gitgutter'
Plug 'rking/ag.vim'
" Plug 'scrooloose/syntastic'
Plug 'ddollar/nerdcommenter'
Plug 'vim-ruby/vim-ruby'
Plug 'Valloric/YouCompleteMe'
Plug 'SirVer/ultisnips'
Plug 'honza/vim-snippets'
Plug 'pangloss/vim-javascript'
Plug 'mxw/vim-jsx'
Plug 'ctrlpvim/ctrlp.vim'
Plug 'junegunn/seoul256.vim'
Plug 'tpope/vim-rails'
Plug 'benmills/vimux'
Plug 'jgdavey/vim-turbux'
Plug 'ngmy/vim-rubocop'
Plug 'junegunn/fzf.vim'
Plug 'flazz/vim-colorschemes'
Plug 'felixhummel/setcolors.vim'
call plug#end()
set t_Co=256
" let g:seoul256_background = 233
colorscheme apprentice
set nocursorline
set nocursorcolumn
let mapleader = ","
nnoremap <SPACE> :nohlsearch<CR>
" FZF
set rtp+=/usr/local/opt/fzf
nmap <LEADER>f :FZF<CR>
let $FZF_DEFAULT_COMMAND= 'ag -g ""'
" Airline stuff
set laststatus=2
set noshowmode
set timeoutlen=1000 ttimeoutlen=0
" Vim trailing whitespace mappings
nnoremap <leader>r :StripWhitespace<CR>
vnoremap <leader>r :StripWhitespace<CR>
" NERDCommenter mappings
nnoremap <leader>c :call NERDComment(0, "toggle")<CR>
vnoremap <leader>c :call NERDComment(0, "toggle")<CR>
" Do not use swapfile
set noswapfile
" Settings for terminals only
if &term =~ '^xterm' || &term == 'screen-256color'
" line in insert mode
let &t_SI .= "\<Esc>[6 q"
" solid block on normal mode
let &t_EI .= "\<Esc>[2 q"
endif
" Utilisnips plugin settings
let g:UltiSnipsExpandTrigger="<c-k>"
let g:UltiSnipsJumpForwardTrigger="<c-b>"
let g:UltiSnipsJumpBackwardTrigger="<c-z>"
" vimux
let VimuxUseNearestPane = 1
let g:turbux_command_rspec = 'time rspec'
let g:turbux_command_test_unit = 'time test'
let g:turbux_command_cucumber = 'time cucumber'
map <C-T> <Plug>SendTestToTmux
map <C-F> <Plug>SendFocusedTestToTmux
",v brings up my .vimrc
map <leader>v :sp ~/.vimrc<CR><C-W>_
",V reloads it -- making all changes active (have to save first)
map <silent> <leader>V :source ~/.vimrc<CR>:filetype detect<CR>:exe ":echo 'vimrc reloaded'"<CR>
" enable per-directory .vimrc files
set exrc
set secure " disable unsafe commands in local .vimrc files
autocmd BufNewFile,BufRead *.slim set ft=slim