aboutsummaryrefslogtreecommitdiffstats
path: root/services/repository/check.go
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2022-04-01 10:55:30 +0800
committerGitHub <noreply@github.com>2022-04-01 10:55:30 +0800
commit124b072f0b69650baff086b9688d198f5a6761af (patch)
treefa18f7930053a8408e124875b5dec20e0309332b /services/repository/check.go
parent3a73645502392110369b5d78fa2c9136e77e4aa2 (diff)
downloadgitea-124b072f0b69650baff086b9688d198f5a6761af.tar.gz
gitea-124b072f0b69650baff086b9688d198f5a6761af.zip
Remove `git.Command.Run` and `git.Command.RunInDir*` (#19280)
Follows #19266, #8553, Close #18553, now there are only three `Run..(&RunOpts{})` functions. * before: `stdout, err := RunInDir(path)` * now: `stdout, _, err := RunStdString(&git.RunOpts{Dir:path})`
Diffstat (limited to 'services/repository/check.go')
-rw-r--r--services/repository/check.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/services/repository/check.go b/services/repository/check.go
index efce308f59..6fb86d0dc3 100644
--- a/services/repository/check.go
+++ b/services/repository/check.go
@@ -77,7 +77,7 @@ func GitGcRepos(ctx context.Context, timeout time.Duration, args ...string) erro
SetDescription(fmt.Sprintf("Repository Garbage Collection: %s", repo.FullName()))
var stdout string
var err error
- stdout, _, err = command.RunWithContextString(&git.RunContext{Timeout: timeout, Dir: repo.RepoPath()})
+ stdout, _, err = command.RunStdString(&git.RunOpts{Timeout: timeout, Dir: repo.RepoPath()})
if err != nil {
log.Error("Repository garbage collection failed for %v. Stdout: %s\nError: %v", repo, stdout, err)