-
Notifications
You must be signed in to change notification settings - Fork 5
/
crosby-vimrc.vim
65 lines (48 loc) · 1.3 KB
/
crosby-vimrc.vim
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
"crosby: From my personal .vimrc, I source:
" source ~/.vim/common-vimrc.vim
" source ~/.vim/crosby-vimrc.vim
let optional = []
"let optional += ["factor"]
let optional += ["nerdtree"]
call optional#include(optional)
" Get the 's' key back
xmap <Leader>s <Plug>Vsurround
set autowrite
set nofoldenable
set wrap
set linebreak
"set nonu
"colorscheme koehler
" Tidy (cheap shot; would like a better plugin)
cabbr tidy %!tidy -q -i -ashtml<CR>
" Croz can't type:
iabbr descrube describe
iabbr deborag deborah
" Buffer navigation: Next and Previous
noremap <C-N> :bn<CR>
noremap <C-P> :bp<CR>
nnoremap <leader>n :NERDTreeToggle<cr>
" Search term highlighting on / off:
noremap <leader>hl :set hlsearch<CR>
noremap <leader>nhl :set nohlsearch<CR>
" Textmate-style arrows shortcut
imap <Space>=><Space>
" Set search highlighting color:
set hl=l:DiffChange
" Windowzizms:
" Run:
map <F5> ,r<CR>
" Save:
noremap <F2> :w<CR>
noremap <F6> :!rake<CR>
" ~/snip is a junk file; call it a customized clipboard
" Write to snip. Either uses current visual selection, or entire buffer
noremap \ws :w! ~/snip<cr>
" Read contents of snip into current buffer
noremap \rs :r ~/snip<cr>
" Edit the snip file
noremap \es :e ~/snip<cr>
" Append to the snip file
noremap \as :w! >> ~/snip<cr>
" Paragraph formatting
noremap Q gqj