diff --git a/autoload/SpaceVim/mapping/space.vim b/autoload/SpaceVim/mapping/space.vim index 395eed408..0511ce35d 100644 --- a/autoload/SpaceVim/mapping/space.vim +++ b/autoload/SpaceVim/mapping/space.vim @@ -184,6 +184,13 @@ function! SpaceVim#mapping#space#init() abort \ 'grep in all loaded buffers', 1) call SpaceVim#mapping#space#def('nnoremap', ['s', 'B'], "call SpaceVim#plugins#flygrep#open({'input' : expand(\"\"), 'files':'@buffers'})", \ 'grep cursor word in all loaded buffers', 1) + " Searching in buffer directory + call SpaceVim#mapping#space#def('nnoremap', ['s', 'd'], "call SpaceVim#plugins#flygrep#open({'input' :" + \ . " input(\"grep pattern:\"), 'dir' : fnamemodify(expand('%'), ':p:h')})", + \ 'grep in arbitrary directory', 1) + call SpaceVim#mapping#space#def('nnoremap', ['s', 'D'], "call SpaceVim#plugins#flygrep#open({'input' :" + \ . " expand(\"\"), 'dir' : fnamemodify(expand('%'), ':p:h')})", + \ 'grep cursor word in arbitrary directory', 1) " Searching in files in an arbitrary directory call SpaceVim#mapping#space#def('nnoremap', ['s', 'f'], "call SpaceVim#plugins#flygrep#open({'input' :" \ . " input(\"grep pattern:\"), 'dir' : input(\"arbitrary dir:\", '', 'dir')})",