(ctx context.Context, args ...string)
| 639 | } |
| 640 | |
| 641 | func (p *Provider) runGit(ctx context.Context, args ...string) (string, error) { |
| 642 | if p.runner != nil { |
| 643 | return p.runner.Run(ctx, p.repoDir, args...) |
| 644 | } |
| 645 | cmd := exec.CommandContext(ctx, "git", args...) |
| 646 | cmd.Dir = p.repoDir |
| 647 | out, err := cmd.CombinedOutput() |
| 648 | return string(out), err |
| 649 | } |
| 650 | |
| 651 | // runGitSplit runs git with stdout and stderr kept apart, for the callers that |
| 652 | // quote the failure back to the user. |
no test coverage detected