From 21b60b309d09595d4c0f83d39138c72249cd4706 Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Wed, 2 Apr 2014 18:09:33 -0400 Subject: [PATCH] Support implicit github username in remote Closes #466. --- plugin/fugitive.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin/fugitive.vim b/plugin/fugitive.vim index fd7b7fe0a8..bdc9de1dfb 100644 --- a/plugin/fugitive.vim +++ b/plugin/fugitive.vim @@ -1936,7 +1936,7 @@ function! s:github_url(repo,url,rev,commit,path,type,line1,line2) abort for domain in domains let domain_pattern .= '\|' . escape(split(domain, '://')[-1], '.') endfor - let repo = matchstr(a:url,'^\%(https\=://\|git://\|git@\)\zs\('.domain_pattern.'\)[/:].\{-\}\ze\%(\.git\)\=$') + let repo = matchstr(a:url,'^\%(https\=://\|git://\|git@\)\=\zs\('.domain_pattern.'\)[/:].\{-\}\ze\%(\.git\)\=$') if repo ==# '' return '' endif