Update README

This commit is contained in:
Junegunn Choi
2016-09-27 02:01:40 +09:00
parent b0a82c4d3f
commit 7060bbb07b
2 changed files with 10 additions and 1 deletions

View File

@@ -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(<q-args>), 0, <bang>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'})
```

View File

@@ -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(<q-args>), 0, <bang>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'})
<