如何用pygit2进行回扣?

2024-04-29 15:26:28 发布

您现在位置:Python中文网/ 问答频道 /正文

我无法用pygit2实现git rebase。在

假设这个回购历史记录,如何使用pygit2topic上恢复topic?(即相当于git rebase master topic):

      A---B---C topic
     /
D---E---F---G master

根据pygit2 documentationmerge_trees可用于此目的。到目前为止,我得到:

^{pr2}$

此操作失败,错误为GitError: failed to create commit: current tip is not the first parent。在

其他的SO问题(herehere)讨论的是快进合并,但不是正确的rebase。在


Tags: git目的master历史记录topicheredocumentation错误