2012-11-30 58 views
0
45825ae 112 min ago Mike  fix bug  master(Blue's conflicted copy 2012-11-30) 
1ba982c 2 hours ago Mike  update doc 

3fbc637 4 hours ago Mike  fix ui bug  master 
193b99e 5 hours ago Mike  fix model bug 

以上是我的git回購的短名單。從我的項目運行git狀態顯示:不允許Git推送:如何解決這個問題?

# On branch master 
# Your branch is ahead of 'origin/master' by 1 commit. 
# 
nothing to commit (working directory clean) 

如果我跑推,它會給我:

http://localhost/myproject.git: push not permitted 

任何想法?

編輯:當我嘗試重新克隆我的項目,它給了我:

fatal: Reference has invalid format: 'refs/heas/master(Blue's conflicted copy 2012-11:30)' 
+0

也許這可能有所幫助:http://stackoverflow.com/questions/2888029/how-to-push-a-local-git-repository-to-another-computer – spinningarrow

+0

感謝您的鏈接,但我不能明白它與我的問題有何關係。 – Mike

回答

0

也許你正在使用錯誤的URL來推動?通常你推送到SSH URL和HTTP只用於拉。

如果你想推送到HTTP,你需要運行git-http-backend,啓用http.receivepack或使用驗證,否則後端將拒絕推送,因爲你看到它。有關更多詳細信息,請參見man page

+0

這是我本地的回購,我用http推送。 – Mike

+0

我已經更新了我的答案,以涵蓋HTTP推送設置。 –