diff --git a/autoload/rhubarb.vim b/autoload/rhubarb.vim index 2a1f01f..34202a0 100644 --- a/autoload/rhubarb.vim +++ b/autoload/rhubarb.vim @@ -30,7 +30,7 @@ function! rhubarb#HomepageForUrl(url) abort for domain in domains let domain_pattern .= '\|' . escape(split(domain, '://')[-1], '.') endfor - let base = matchstr(a:url, '^\%(https\=://\|git://\|git@\|ssh://git@\)\=\zs\('.domain_pattern.'\)[/:].\{-\}\ze\%(\.git\)\=$') + let base = matchstr(a:url, '^\%(https\=://\|git://\|git@\|ssh://git@\)\=\zs\('.domain_pattern.'\)[/:].\{-\}\ze\%(\.git\)\=/\=$') if index(domains, 'http://' . matchstr(base, '^[^:/]*')) >= 0 return 'http://' . tr(base, ':', '/') elseif !empty(base)