1
我對git的狀態此消息:git的狀態:上分行XXX你的分支是提前10原產/ YYY的承諾
# On branch YYY
# Your branch is ahead of 'origin/XXX' by 10 commits.
#
nothing to commit (working directory clean)
科YYY是分支XXX的孩子。但通常在git狀態,我會預計:
# On branch YYY
# Your branch is ahead of 'origin/YYY' by 10 commits.
#
nothing to commit (working directory clean)
Git fetch並不能解決問題。 任何想法? (過濾後)的git branch -avvv
輸出:
* XXX 0d64037 [origin/YYY: ahead 10] test
remotes/origin/XXX 0d64037 test
找不到--u選項 – albanx 2014-09-25 08:30:23
好的我解決了:git branch XXX --set-upstream origin/YYY然後我按照你的建議推送了。你可以添加這個答案。謝謝。 – albanx 2014-09-25 08:35:58
@albanx偉大。 '-u'適用於git 1.8或更高版本(請參閱http://stackoverflow.com/a/4879224/6309) – VonC 2014-09-25 08:37:07