diff options
author | Matthew Lemon <y@yulqen.org> | 2023-10-10 13:16:36 +0100 |
---|---|---|
committer | Matthew Lemon <y@yulqen.org> | 2023-10-10 13:16:36 +0100 |
commit | 6048e07c90f14426df02f9959a56181041381cf8 (patch) | |
tree | fd852bc70190566a5341e222162ebe3bb6d57aee /vim/vimrc | |
parent | 078b76ba1b12cfe23695c2c235f212959ad97587 (diff) |
Adds a FZF function to search in git repo
Diffstat (limited to 'vim/vimrc')
-rw-r--r-- | vim/vimrc | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -346,3 +346,12 @@ augroup encrypted \ setlocal nobin augroup END " }}} +" GitFZF {{{ +" from https://git.sr.ht/~sircmpwn/dotfiles/tree/master/item/.vimrc +function! GitFZF() + let path = trim(system('cd '.shellescape(expand('%:p:h')).' && git rev-parse --show-toplevel')) + exe 'FZF ' . path +endfunction +command! GitFZF call GitFZF() +nnoremap <leader><C-f> :GitFZF<CR> +" }}} |