From 7060bbb07b9a3e209db2a092fe3c05bfe60f7000 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Tue, 27 Sep 2016 02:01:40 +0900 Subject: [PATCH] Update README --- README.md | 5 +++++ doc/fzf-vim.txt | 6 +++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index b418424..64b81ab 100644 --- a/README.md +++ b/README.md @@ -157,6 +157,11 @@ let g:fzf_commands_expect = 'alt-enter,ctrl-x' You can use autoload functions to define your own commands. ```vim +" git grep +command! -bang -nargs=* GGrep + \ call fzf#vim#grep('git grep --line-number '.shellescape(), 0, 0) + +" We use VimEnter event so that the code is run after fzf.vim is loaded autocmd VimEnter * command! Colors \ call fzf#vim#colors({'left': '15%', 'options': '--reverse --margin 30%,0'}) ``` diff --git a/doc/fzf-vim.txt b/doc/fzf-vim.txt index c4a0e56..2752ea5 100644 --- a/doc/fzf-vim.txt +++ b/doc/fzf-vim.txt @@ -183,7 +183,11 @@ Advanced customization using autoload functions~ You can use autoload functions to define your own commands. > - " Advanced customization using autoload functions + " git grep + command! -bang -nargs=* GGrep + \ call fzf#vim#grep('git grep --line-number '.shellescape(), 0, 0) + + " We use VimEnter event so that the code is run after fzf.vim is loaded autocmd VimEnter * command! Colors \ call fzf#vim#colors({'left': '15%', 'options': '--reverse --margin 30%,0'}) <