mirror of
https://github.com/cooperspencer/gickup
synced 2024-10-18 07:38:08 +02:00
fix temp clone as well
This commit is contained in:
parent
45056fce58
commit
b7c3239c6c
@ -511,11 +511,17 @@ func VerifyHost(host string, remote net.Addr, key gossh.PublicKey) error {
|
||||
func TempClone(repo types.Repo, tempdir string) (*git.Repository, error) {
|
||||
var auth transport.AuthMethod
|
||||
if repo.Token != "" {
|
||||
if repo.NoTokenUser {
|
||||
auth = &http.BasicAuth{
|
||||
Username: repo.Token,
|
||||
}
|
||||
} else {
|
||||
auth = &http.BasicAuth{
|
||||
Username: "xyz",
|
||||
Password: repo.Token,
|
||||
}
|
||||
}
|
||||
}
|
||||
if repo.Origin.LFS {
|
||||
g, err := gitcmd.New()
|
||||
if err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user