From d70d74a2aed23e0121ddf454034c01f6cc50c66b Mon Sep 17 00:00:00 2001 From: yystopf Date: Mon, 17 Apr 2023 11:11:59 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=94=B9=EF=BC=9A=E4=BD=BF=E7=94=A8gi?= =?UTF-8?q?tcmd=E4=BF=9D=E8=AF=81=E4=B8=8D=E4=BC=9Abroken?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/git/repo_stats.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/git/repo_stats.go b/modules/git/repo_stats.go index fa54183..dac957f 100644 --- a/modules/git/repo_stats.go +++ b/modules/git/repo_stats.go @@ -151,7 +151,7 @@ func GetPaginateCodeAuthors(repo *gitea_git.Repository, fromTime time.Time, bran var authors []*CodeActivityAuthor since := fromTime.Format(time.RFC3339) - authorCmd := gitea_git.NewCommand(repo.Ctx, "log", "--no-merges", "--format=%aN <%aE>", "--date=iso").AddDynamicArguments("--since='%s'", since) + authorCmd := gitea_git.NewCommand(repo.Ctx, "log", "--no-merges", "--format=%aN <%aE>", "--date=iso", gitea_git.CmdArg(fmt.Sprintf("--since='%s'", since))) if len(branch) == 0 { authorCmd.AddArguments("--branches=*") } else { @@ -201,7 +201,7 @@ func GetPaginateCodeAuthors(repo *gitea_git.Repository, fromTime time.Time, bran _ = stdoutReader.Close() _ = stdoutWriter.Close() }() - gitCmd := gitea_git.NewCommand(repo.Ctx, "log", "--numstat", "--no-merges", "--pretty=format:---%n%h%n%aN%n%aE%n", "--date=iso", gitea_git.CmdArg(fmt.Sprintf("--author=%s", filterAuthor))).AddDynamicArguments("--since='%s'", since) + gitCmd := gitea_git.NewCommand(repo.Ctx, "log", "--numstat", "--no-merges", "--pretty=format:---%n%h%n%aN%n%aE%n", "--date=iso", gitea_git.CmdArg(fmt.Sprintf("--author=%s", filterAuthor)), gitea_git.CmdArg(fmt.Sprintf("--since='%s'", since))) if len(branch) == 0 { gitCmd.AddArguments("--branches=*") } else {