mirror of
https://github.com/tpope/vim-rhubarb.git
synced 2025-12-06 12:14:26 +08:00
Fix inclusion of trailing quote when parsing config file
This has no effect on the current behavior because we're only checking for the presence of the URL, not actually using it. Still, this will prevent a bug from creeping in if rhubarb#HomepageForUrl() ever gets more strict.
This commit is contained in:
@@ -24,7 +24,7 @@ function! s:SetUpMessage(filename) abort
|
|||||||
let config_file = FugitiveFind('.git/config', dir)
|
let config_file = FugitiveFind('.git/config', dir)
|
||||||
let config = filereadable(config_file) ? readfile(config_file) : []
|
let config = filereadable(config_file) ? readfile(config_file) : []
|
||||||
if !empty(filter(config,
|
if !empty(filter(config,
|
||||||
\ '!empty(rhubarb#HomepageForUrl(matchstr(v:val, ''^\s*url\s*=\s*"\=\zs\S*'')))'))
|
\ '!empty(rhubarb#HomepageForUrl(matchstr(v:val, ''^\s*url\s*=\s*"\=\zs[^[:space:]"]*'')))'))
|
||||||
setlocal omnifunc=rhubarb#Complete
|
setlocal omnifunc=rhubarb#Complete
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|||||||
Reference in New Issue
Block a user