diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2019-06-01 21:19:31 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2019-06-01 21:21:11 +1200 |
commit | 3d3acdfc3395b34a2fa1398bc13dc3bd19a275f6 (patch) | |
tree | 49cc300dbcd92c550fee954f8bf381169eb59de5 | |
parent | Update vim-write-mkpath to v2.0.2 (diff) | |
download | dotfiles-3d3acdfc3395b34a2fa1398bc13dc3bd19a275f6.tar.gz dotfiles-3d3acdfc3395b34a2fa1398bc13dc3bd19a275f6.zip |
Remap \g and \G for printing and moving to file
-rw-r--r-- | vim/vimrc | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -312,8 +312,10 @@ nnoremap <Leader>f :<C-U>setlocal formatoptions?<CR> " \F reloads filetype plugins nnoremap <Leader>F :<C-U>doautocmd filetypedetect BufRead<CR> -" \g changes directory to the current file's location -nnoremap <Leader>g :<C-U>cd %:h<Bar>pwd<CR> +" \g shows the current file's fully expanded path +nnoremap <Leader>g :<C-U>echo expand('%:p')<CR> +" \G changes directory to the current file's location +nnoremap <Leader>G :<C-U>cd %:h<Bar>pwd<CR> " \h toggles highlighting search results nnoremap <Leader>h :<C-U>set hlsearch! hlsearch?<CR> |