Skip to content

Commit

Permalink
Vim: :F and :E search in git repository
Browse files Browse the repository at this point in the history
  • Loading branch information
andys8 committed Jan 21, 2024
1 parent 29ef40f commit 9195c13
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions vimrc
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ set grepprg=rg\ --vimgrep
cnoremap <C-P> <C-R>=expand("%:p:h") . "/" <CR>
nnoremap <silent> <leader>b :Buffers<CR>
nnoremap <silent> <leader>e :FZF<CR>
nnoremap <silent> <leader>E :Gcd<CR>:FZF<CR>
"Recovery commands from history through FZF
nmap <leader>y :History:<CR>
Expand Down
2 changes: 1 addition & 1 deletion vimrc.local
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ set tags+=tags;tags.vendors;,tags;

" Search with Rg (overwrites vimrc)
nnoremap <silent> <leader>f :Rg<CR>
nnoremap <silent> <leader>F :Rg <c-r><c-w><cr>
nnoremap <silent> <leader>F :Gcd<CR>:Rg<CR>

" Rg search command
command! -bang -nargs=* Rg
Expand Down

0 comments on commit 9195c13

Please sign in to comment.