git 错误:远程 HEAD 不明确,可能是以下之一
分支并推送到远程后,git remote show origin
给出报告
HEAD branch (remote HEAD is ambiguous, may be one of the following):
master
otherbranch
What does the imply?
这是一个严重错误吗?
remote origin
Fetch URL: [email protected]:/home/gituser/repos/csfsconf.git
Push URL: [email protected]:/home/gituser/repos/csfsconf.git
HEAD branch (remote HEAD is ambiguous, may be one of the following):
master
otherbranch
After branching and pushing to the remote, a git remote show origin
gives the report
HEAD branch (remote HEAD is ambiguous, may be one of the following):
master
otherbranch
What does the imply?
It is a critical error?
remote origin
Fetch URL: [email protected]:/home/gituser/repos/csfsconf.git
Push URL: [email protected]:/home/gituser/repos/csfsconf.git
HEAD branch (remote HEAD is ambiguous, may be one of the following):
master
otherbranch
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以在此博文
这(推送新的当前分支)将引入对远程存储库的新 HEAD 引用。
如果您查看此警告消息的 Git 源,它会尝试获取通过
get_head_names()
调用远程 HEAD 名称:如 此补丁:
(请参阅代码在这里)
You can see the same warning in this blog post
That (pushing a new current branch) will introduce a new HEAD reference to the remote repo.
If you look at the Git sources for this warning message, it tries to get the remote HEAD names through
get_head_names()
which calls :As described in this patch:
(see the code here)
线程位于 http://forums.wf.klevo.sk/comments.php ?DiscussionID=155对此主题进行了讨论。该线程特别提到:
也许您需要标记当前分支?如果没有,线程的其余部分可能会有所帮助。
The thread at http://forums.wf.klevo.sk/comments.php?DiscussionID=155 has a discussion of this topic. In particular the thread mentions:
Perhaps you need to mark your current branch? If not, the rest of the thread may help.