修复:邮箱匹配规则更改
This commit is contained in:
parent
98d687ab3f
commit
a032635665
|
@ -37,7 +37,13 @@ func GetCodeActivityStatsWithoutSince(repo *gitea_git.Repository, branch string,
|
|||
|
||||
stats := &CodeActivityStats{}
|
||||
|
||||
authorStdout, _, runErr := gitea_git.NewCommand(repo.Ctx, "log", "--all", "--format='%aN <%cE>'").RunStdString(&gitea_git.RunOpts{Dir: repo.Path})
|
||||
authorCmd := gitea_git.NewCommand(repo.Ctx, "log", "--no-merges", "--format=%aN <%aE>", "--date=iso")
|
||||
if len(branch) == 0 {
|
||||
authorCmd.AddArguments("--branches=*")
|
||||
} else {
|
||||
authorCmd.AddArguments("--first-parent").AddDynamicArguments(branch)
|
||||
}
|
||||
authorStdout, _, runErr := authorCmd.RunStdString(&gitea_git.RunOpts{Dir: repo.Path})
|
||||
if runErr != nil {
|
||||
return total, nil, runErr
|
||||
}
|
||||
|
@ -56,7 +62,6 @@ func GetCodeActivityStatsWithoutSince(repo *gitea_git.Repository, branch string,
|
|||
authorSet[author] = true
|
||||
authorArr[total] = author
|
||||
total++
|
||||
author = strings.ReplaceAll(author, "'", "")
|
||||
if skip > 0 {
|
||||
skip--
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue