【发布时间】:2014-09-11 22:26:18
【问题描述】:
在使用 Git GUI 对远程分支 releases/rel_5.4.1 进行检查后,当我尝试 push 时看到此意外错误消息:
fatal: The upstream branch of your current branch does not match
the name of your current branch. To push to the upstream branch
on the remote, use
git push origin HEAD:releases/rel_5.4.1
To push to the branch of the same name on the remote, use
git push origin rel_5.4.1
我不知道 Git 在说什么。我可能想推到origin releases/rel_5.4.1,因为那是我签出的分支。所以我觉得这两个选项都不正确。
git status 说我在分支rel_5.4.1。
这是出现在我的.git/config 中的分支:
[branch "rel_5.4.1"]
remote = origin
merge = refs/heads/releases/rel_5.4.1
发生了什么事?
【问题讨论】:
-
你用的是什么版本的git(还有什么平台)?
标签: git push remote-branch