Merge branch 'master' into feature/ripgrep

This commit is contained in:
Steven Barragán
2017-02-22 17:15:59 -08:00
committed by GitHub
4 changed files with 9 additions and 6 deletions

View File

@@ -186,7 +186,7 @@ of plugins above to learn more.
* `,F` - same as `,f` but in a vertical split * `,F` - same as `,f` but in a vertical split
* `,gf` or `Ctrl-f` - same as vim normal gf (go to file), but in a vertical split (works with file.rb:123 line numbers also) * `,gf` or `Ctrl-f` - same as vim normal gf (go to file), but in a vertical split (works with file.rb:123 line numbers also)
* `gF` - standard vim mapping, here for completeness (go to file at line number) * `gF` - standard vim mapping, here for completeness (go to file at line number)
* `K` - Search the current word under the cursor and show results in quickfix window * `,k` - Search the current word under the cursor and show results in quickfix window
* `,K` - Grep the current word up to next exclamation point (useful for ruby foo! methods) * `,K` - Grep the current word up to next exclamation point (useful for ruby foo! methods)
* `Cmd-*` - highlight all occurrences of current word (similar to regular `*` except doesn't move) * `Cmd-*` - highlight all occurrences of current word (similar to regular `*` except doesn't move)
* `,hl` - toggle search highlight on and off * `,hl` - toggle search highlight on and off

View File

@@ -10,11 +10,11 @@ function! GetVisual()
return selection return selection
endfunction endfunction
"grep the current word using K (mnemonic Kurrent) "grep the current word using ,k (mnemonic Kurrent)
nnoremap <silent> K :Rg <cword><CR> nnoremap <silent> ,k :Rg <cword><CR>
"grep visual selection "grep visual selection
vnoremap K :<C-U>execute "Rg " . GetVisual()<CR> vnoremap ,k :<C-U>execute "Rg " . GetVisual()<CR>
"grep current word up to the next exclamation point using ,K "grep current word up to the next exclamation point using ,K
nnoremap ,K viwf!:<C-U>execute "Rg " . GetVisual()<CR> nnoremap ,K viwf!:<C-U>execute "Rg " . GetVisual()<CR>

View File

@@ -5,3 +5,5 @@ Bundle 'jtratner/vim-flavored-markdown.git'
Bundle 'scrooloose/syntastic.git' Bundle 'scrooloose/syntastic.git'
Bundle 'nelstrom/vim-markdown-preview' Bundle 'nelstrom/vim-markdown-preview'
Bundle 'skwp/vim-html-escape' Bundle 'skwp/vim-html-escape'
Bundle 'mxw/vim-jsx'
Bundle 'jparise/vim-graphql'

View File

@@ -2,5 +2,6 @@ Bundle "jistr/vim-nerdtree-tabs.git"
Bundle "scrooloose/nerdtree.git" Bundle "scrooloose/nerdtree.git"
Bundle "ctrlpvim/ctrlp.vim" Bundle "ctrlpvim/ctrlp.vim"
Bundle 'JazzCore/ctrlp-cmatcher' Bundle 'JazzCore/ctrlp-cmatcher'
Bundle 'junegunn/fzf'
Bundle "xolox/vim-misc" Bundle "xolox/vim-misc"
Bundle "xolox/vim-session" Bundle "xolox/vim-session"