You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 19, 2021. It is now read-only.
terminate called after throwing an instance of 'cppgit2::git_exception'
what(): failed to create commit: current tip is not the first parent
Aborted (core dumped)
Ok, no problem. Looks like libgit wants us to put head commit to the list of parents. So, I changed your example code to:
Hello, your example about git add and git commit only works with non-existing repo.
Trying to launch it against pre-cloned one leads to
Ok, no problem. Looks like libgit wants us to put head commit to the list of parents. So, I changed your example code to:
Changes:
1:
addedauto head_commit = repo.lookup_commit(repo.head().target());
2:
changedto
However this time all I get is
As you see. technically the code does work and commit is made, however I cannot rid of that exception which breaks the rest of the code.
The text was updated successfully, but these errors were encountered: