2014-10-20 28 views
1

我使用cvs2git將cvs repo轉換爲git。這個項目/回購有多個分支和標籤。無論如何,我能夠(沒有得到任何錯誤味精)將此CVS回購轉換爲GIT。但是當我把git項目推到github時,我得到這個錯誤。我認爲這可能是我把它推給師父,但我有多個分支。如果是這樣的話,我該如何將多個分支推送到github?謝謝!cvs2git隱藏cvs git並推送多個分支獲取:錯誤:src refspec主不匹配任何

這裏是我跑的命令:

git remote add origin https://github.com/mygithub/MyProject.git 
git push -u origin master 

Complete Error: 
error: src refspec master does not match any. 
error: failed to push some refs to 'https://github.com/mygithub/MyProject.git'. 

回答

2

你有沒有在你的本地倉庫命名主分支? git branch會告訴你你當地的分支機構。

這可能是你想要做git push --mirror

--mirror Instead of naming each ref to push, specifies that all refs under refs/ (which includes but is not limited to refs/heads/, refs/remotes/, and refs/tags/) be mirrored to the remote repository. Newly created local refs will be pushed to the remote end, locally updated refs will be force updated on the remote end, and deleted refs will be removed from the remote end. This is the default if the configuration option remote..mirror is set.

+0

剛跑「混帳秀分支」,並獲得「中顯示無轉速。」我想我有一些「git fast-import」的問題。謝謝! – topcan5 2014-10-20 16:07:41

相關問題