Skip to content

Commit

Permalink
Support implicit github username in remote
Browse files Browse the repository at this point in the history
Closes #466.
  • Loading branch information
tpope committed Apr 2, 2014
1 parent 9649b02 commit 21b60b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugin/fugitive.vim
Expand Up @@ -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
Expand Down

0 comments on commit 21b60b3

Please sign in to comment.