From 3ca799ebbfc351f14126b0d1948a818daace98d4 Mon Sep 17 00:00:00 2001 From: yan Date: Sun, 11 Dec 2011 01:52:46 -0800 Subject: [PATCH] Better key mappings for gitgrep which don't override standard behavior --- vimrc | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/vimrc b/vimrc index 412f91ea..b9fb4763 100644 --- a/vimrc +++ b/vimrc @@ -33,6 +33,9 @@ set noswapfile set nobackup set nowb +" Disable cursor blink +set gcr=a:blinkon0 + " persistent undos - undo after you re-open the file " but this gives warnings under command line vim " use only in macvim @@ -228,9 +231,8 @@ nnoremap Z nnoremap K :GitGrep "open up a git grep line, with a quote started for the search -"mnemonic: the letter O looks like a magnifying glass or goggles (search) -nnoremap O :GitGrep " -nnoremap P :GitGrepCurrentPartial +nnoremap ,gg :GitGrep " +nnoremap ,gcp :GitGrepCurrentPartial " create <%= foo %> erb tags using Ctrl-k in edit mode imap <%= %>3hi @@ -317,11 +319,10 @@ nnoremap W :w " RSI Prevention - keyboard remaps " ======================================== " in code, undescores and dashes are very commmon, but -" the key is really far away. remap Apple-k to give us -" underscores and Apple-Shift-K to give dashes. -" home row for the win! +" the key is really far away. remap the middle fingers +" with the command key to do what we want (type dashes) imap _ -imap - +imap - " fugitive.git @@ -408,3 +409,9 @@ inoremap pumvisible() ? "\" : "\" let g:CommandTMaxHeight = 5 let g:CommandTMatchWindowReverse = 1 nmap ,t :CommandT + + +" Some color remaps +" If statements and def statements should look similar +" so you can see the flow +hi! link rubyDefine rubyControl