我在GIT中下面的遙控器:無法推到輔助遠程
origin file:///some_path/project/ (fetch)
origin file:///some_path/project/ (push)
release file:///some_other_path/project/ (fetch)
release file:///some_other_path/project/ (push)
和我稱:
git push --set-upstream origin --all
git remote update
當我推到origin
:
git push origin
一切正常,但是當我嘗試推送到release
時:
git push release
我得到以下錯誤:
fatal: You are pushing to remote 'release', which is not the upstream of
your current branch 'master', without telling me what to push
to update which remote branch.
爲什麼?
你說得對。嗯,所以我認爲沒有辦法預先指定每個遠程的默認推送分支? – 2013-05-06 22:35:00
有一種方法可以指定分支的默認遠程引用。你已經通過'--set-upstream origin --all'完成了這項工作。但是,如@sleske所示,還有一個'push.default'配置參數,它指定推送所有遠程存儲庫的默認分支。 – harpun 2013-05-06 22:40:26