From 027f03aae02427dcbc6903531ce7428875c56f66 Mon Sep 17 00:00:00 2001 From: Matěj Cepl Date: Tue, 27 Apr 2021 10:27:08 +0200 Subject: fix(plugin): gx works again --- plugin/spec.vim | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'plugin/spec.vim') diff --git a/plugin/spec.vim b/plugin/spec.vim index 5583a29..67b63a6 100644 --- a/plugin/spec.vim +++ b/plugin/spec.vim @@ -3,17 +3,17 @@ noremap gG :,!abbrevURL " Doesn't work because of gh#vim/vim#4738 let g:netrw_browsex_viewer='setsid osurl' -" This is just temporary workaround until the above issue is truly -" resolved. -function! OpenURLUnderCursor() - let s:uri = expand('') - echom "s:uri = " . s:uri - " let s:uri = matchstr(getline('.'), '[a-z]*(:\/\/\|#)[^ >,;()]*') - " let s:uri = shellescape(s:uri, 1) - " echom "s:uri = " . s:uri - if s:uri != '' - silent exec "!osurl '".s:uri."'" - :redraw! - endif -endfunction -nnoremap gx :call OpenURLUnderCursor() +" " This is just temporary workaround until the above issue is truly +" " resolved. +" function! OpenURLUnderCursor() +" let s:uri = expand('') +" echom "s:uri = " . s:uri +" " let s:uri = matchstr(getline('.'), '[a-z]*(:\/\/\|#)[^ >,;()]*') +" " let s:uri = shellescape(s:uri, 1) +" " echom "s:uri = " . s:uri +" if s:uri != '' +" silent exec "!osurl '".s:uri."'" +" :redraw! +" endif +" endfunction +" nnoremap gx :call OpenURLUnderCursor() -- cgit