是否可以在libgit2中推送提交而不是引用,即基本上相当于git push {remote} {commit}:{branch}
?
当我尝试使用git_remote_upload()
之类的refspec来调用e9c46cd9071113c95f6b3fb48b74f98056abf7a1:refs/heads/master
时,它会因此错误而失败:
没有这样的参考' e9c46cd9071113c95f6b3fb48b74f98056abf7a1'
我做错了还是不支持此功能?
答案 0 :(得分:1)
使用推送的人尚未添加此功能。 push函数期望refspecs使用双方的引用。