mirror of
https://github.com/go-gitea/gitea
synced 2025-07-15 23:17:19 +00:00
go-version constraints ignore pre-releases (#13234)
Go-version constraints ignore pre-releases. Rather than change the library further this PR simply changes the git version comparison to use simple version compare ignoring the issue of pre-releases. Signed-off-by: Andrew Thornton <art27@cantab.net>
This commit is contained in:
@@ -40,7 +40,7 @@ func (repo *Repository) CheckAttribute(opts CheckAttributeOpts) (map[string]map[
|
||||
}
|
||||
|
||||
// git check-attr --cached first appears in git 1.7.8
|
||||
if opts.CachedOnly && CheckGitVersionConstraint(">= 1.7.8") == nil {
|
||||
if opts.CachedOnly && CheckGitVersionAtLeast("1.7.8") == nil {
|
||||
cmdArgs = append(cmdArgs, "--cached")
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user