vendor: update github.com/gogs/git-module

This commit is contained in:
Unknwon
2018-08-17 23:15:26 +08:00
parent ac73d43444
commit ba7b2cc1f6
3 changed files with 11 additions and 6 deletions

View File

@@ -10,7 +10,7 @@ import (
"time"
)
const _VERSION = "0.6.9"
const _VERSION = "0.7.0"
func Version() string {
return _VERSION

View File

@@ -176,10 +176,15 @@ func Pull(repoPath string, opts PullRemoteOptions) error {
return err
}
// PushWithEnvs pushs local commits to given remote branch with given environment variables.
func PushWithEnvs(repoPath, remote, branch string, envs []string) error {
_, err := NewCommand("push", remote, branch).AddEnvs(envs...).RunInDir(repoPath)
return err
}
// Push pushs local commits to given remote branch.
func Push(repoPath, remote, branch string) error {
_, err := NewCommand("push", remote, branch).RunInDir(repoPath)
return err
return PushWithEnvs(repoPath, remote, branch, nil)
}
type CheckoutOptions struct {