-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update libgit2 to 1.3.0 #321
Conversation
d811077
to
f618292
Compare
@@ -1413,3 +1435,77 @@ func mergeBranchIntoHead(repo *git.Repository, pushBranch string) { | |||
}) | |||
Expect(err).NotTo(HaveOccurred()) | |||
} | |||
|
|||
// copied from source-controller/pkg/git/libgit2/checkout.go | |||
func commitFile(repo *git2go.Repository, path, content string, time time.Time) (*git2go.Oid, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should rewrite the commit logic using libgit2
func commitChangedManifests(tracelog logr.Logger, repo *gogit.Repository, absRepoPath string, ent *openpgp.Entity, author *object.Signature, message string) (string, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I rewrote the gitInitRepo with libgit2, which was enough to remove the need for the adhoc fix.
Can we go ahead with the libgit2 to 1.3.0
on this PR and then any further rewrite/replacement of go-git we can deal on a separate PR.
9d0de93
to
bc4a4e0
Compare
Signed-off-by: Paulo Gomes <[email protected]>
Signed-off-by: Paulo Gomes <[email protected]>
Signed-off-by: Paulo Gomes <[email protected]>
Signed-off-by: Paulo Gomes <[email protected]>
Signed-off-by: Paulo Gomes <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Thanks @pjbgf
Update source controller to
v0.21.3
(fluxcd/source-controller#589) and update libgit2 tov1.3.0
.Fixes #320