diff --git a/status/url.go b/status/url.go index 86dac97..3a4cf54 100644 --- a/status/url.go +++ b/status/url.go @@ -23,7 +23,9 @@ func EqualRepoURLs(rawurl0, rawurl1 string) bool { } u.Scheme, v.Scheme = "", "" // Ignore scheme. u.User, v.User = nil, nil // Ignore username and password information. - return u.String() == v.String() + // Ignore the .git extension, which GitHub ignores for the git User-Agent. + u.Path, v.Path = strings.TrimSuffix(u.Path, ".git"), strings.TrimSuffix(v.Path, ".git") + return strings.ToLower(u.String()) == strings.ToLower(v.String()) } // FormatRepoURL tries to rewrite rawurl to follow the same format as layout URL.