diff options
-rw-r--r-- | autoload/grappele.vim | 2 | ||||
-rw-r--r-- | plugin/grappele.vim | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/autoload/grappele.vim b/autoload/grappele.vim index c2257d8..423723b 100644 --- a/autoload/grappele.vim +++ b/autoload/grappele.vim @@ -14,7 +14,7 @@ function! grappele#Recall(mode) let l:line = visualmode() . l:line endif - execute 'normal! ' . l:line . 'G' + return l:line . 'G' endif endfunction diff --git a/plugin/grappele.vim b/plugin/grappele.vim index 21c5cc7..f85b2b4 100644 --- a/plugin/grappele.vim +++ b/plugin/grappele.vim @@ -5,8 +5,8 @@ let g:loaded_grappele = 1 nnoremap <silent> <Plug>Grappele grappele#Grappele(v:count, 'n') -nnoremap <silent> <Plug>GrappeleRecall :<C-u>call grappele#Recall('n')<cr> -vnoremap <silent> <Plug>GrappeleRecall :<C-u>call grappele#Recall('v')<cr> +nnoremap <silent> <expr> <Plug>GrappeleRecall grappele#Recall('n') +vnoremap <silent> <expr> <Plug>GrappeleRecall grappele#Recall('v') onoremap <silent> <expr> <Plug>GrappeleRecall grappele#ORecall() if !hasmapto('<Plug>Grappele') || !maparg('G', 'n') |