forked from toolshed/abra
refactor: use central logger
This commit is contained in:
@ -3,9 +3,9 @@ package git
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"coopcloud.tech/abra/pkg/log"
|
||||
"github.com/go-git/go-git/v5"
|
||||
"github.com/go-git/go-git/v5/plumbing"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
// Check if a branch exists in a repo. Use this and not repository.Branch(),
|
||||
@ -90,11 +90,11 @@ func CheckoutDefaultBranch(repo *git.Repository, repoPath string) (plumbing.Refe
|
||||
}
|
||||
|
||||
if err := worktree.Checkout(checkOutOpts); err != nil {
|
||||
logrus.Debugf("failed to check out %s in %s", branch, repoPath)
|
||||
log.Debugf("failed to check out %s in %s", branch, repoPath)
|
||||
return branch, err
|
||||
}
|
||||
|
||||
logrus.Debugf("successfully checked out %v in %s", branch, repoPath)
|
||||
log.Debugf("successfully checked out %v in %s", branch, repoPath)
|
||||
|
||||
return branch, nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user