fix(client): set push.default=current for git
This commit is contained in:
parent
24ec99bacd
commit
77547cedce
@ -198,9 +198,11 @@ func (c Client) PushRepo(repo api.Repo) (err error) {
|
|||||||
remote := fmt.Sprintf("git://%s/%s", addr, repo.Name)
|
remote := fmt.Sprintf("git://%s/%s", addr, repo.Name)
|
||||||
log.Debug().Msgf("git proxy remote: %v", remote)
|
log.Debug().Msgf("git proxy remote: %v", remote)
|
||||||
|
|
||||||
raw, err := exec.Command("git", "--work-tree", repo.Path, "push", "--force", remote).
|
raw, err := exec.Command("git", "-c", "push.default=current",
|
||||||
|
"--work-tree", repo.Path, "push", "--force", remote).
|
||||||
CombinedOutput()
|
CombinedOutput()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
log.Error().Msgf("push repo %v\n%v", repo, string(raw))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user