aboutsummaryrefslogtreecommitdiffstats
path: root/services/repository/files/patch.go
diff options
context:
space:
mode:
Diffstat (limited to 'services/repository/files/patch.go')
-rw-r--r--services/repository/files/patch.go11
1 files changed, 5 insertions, 6 deletions
diff --git a/services/repository/files/patch.go b/services/repository/files/patch.go
index 904512f3f3..240cb4fe2c 100644
--- a/services/repository/files/patch.go
+++ b/services/repository/files/patch.go
@@ -145,12 +145,11 @@ func ApplyDiffPatch(ctx context.Context, repo *repo_model.Repository, doer *user
}
cmd := git.NewCommand(ctx, args...)
- if err := cmd.RunWithContext(&git.RunContext{
- Timeout: -1,
- Dir: t.basePath,
- Stdout: stdout,
- Stderr: stderr,
- Stdin: strings.NewReader(opts.Content),
+ if err := cmd.Run(&git.RunOpts{
+ Dir: t.basePath,
+ Stdout: stdout,
+ Stderr: stderr,
+ Stdin: strings.NewReader(opts.Content),
}); err != nil {
return nil, fmt.Errorf("Error: Stdout: %s\nStderr: %s\nErr: %v", stdout.String(), stderr.String(), err)
}