Minimum viable URL escaping in :Gbrowse

Closes https://github.com/tpope/vim-fugitive/issues/703.
This commit is contained in:
Tim Pope 2015-12-26 14:11:54 -05:00
parent 09cdce7add
commit 9f768cd3bc

View File

@ -2275,6 +2275,7 @@ function! s:Browse(bang,line1,count,...) abort
call s:throw("Instaweb failed to start and '".remote."' is not a supported remote")
endif
let url = s:gsub(url, '[ <>]', '\="%".printf("%02X",char2nr(submatch(0)))')
if a:bang
if has('clipboard')
let @* = url