2012-02-13 42 views
2

我设置了egit以在我的大学计算机上使用我的GitHub回购协议。
回购有5个分支,包括主人和我的本地副本也有这些分支,所以我可以去Team -> Switch to并在日食中选择所需的分支。从github导入所有分支

在我的笔记本电脑上,我设置了Egit并克隆了回购。
我在导入时选择了所有分支,但是在git存储库选项卡的Local下,它只有主设备,所有其他分支都在远程跟踪下。
如果我切换到远程跟踪分支进行修改,提交,然后按我得到以下错误:

An internal Exception occurred during push: Nothing to push. 

任何人都知道我做错了吗? 谢谢

+0

HEAD没有ü尝试使用--force? – Venki 2012-02-13 20:59:05

+0

eclipse中的选项在哪里? – sam 2012-02-13 21:09:58

回答

4

If I switch to a Remote Tracking branch make a change, commit and then push I get the following error

您没有从您刚切换到的远程跟踪分支创建本地分支。
这意味着你在detached HEAD mode,因此“没有推动”。
见 “Git Lesson: Be mindful of a detached head”:

(无HEAD :)

no head

Team -> Switch To -> New Branch 

将足以解决这个问题,然后将其推送到远程的。

(新的分支:)

HEAD on the new branch