你能解釋這個工作流程有什麼問題嗎?爲什麼我無法推送到這個裸倉庫?
$ git init --bare bare
Initialized empty Git repository in /work/fun/git_experiments/bare/
$ git clone bare alice
Cloning into alice...
done.
warning: You appear to have cloned an empty repository.
$ cd alice/
$ touch a
$ git add a
$ git commit -m "Added a"
[master (root-commit) 70d52d4] Added a
0 files changed, 0 insertions(+), 0 deletions(-)
create mode 100644 a
$ git push
No refs in common and none specified; doing nothing.
Perhaps you should specify a branch such as 'master'.
fatal: The remote end hung up unexpectedly
error: failed to push some refs to '/work/fun/git_experiments/bare'
不git push
總是推到我從克隆的資源庫?
你不應該指定分支推? – Rekin 2011-05-27 21:14:48
不是克隆後!問題解決後,它工作的很好,不需要指定分支......只是在第一次簽出一個空的存儲庫時會發生這種非常非常煩人的事情......他們應該解決這個問題。 – 2012-05-23 16:49:09
希望這篇文章對上面的人有用 - http://samranga.blogspot.com/2015/07/create-git-bitbucket-repository-from.html?view=sidebar問題中的錯誤可以即使試圖從已經存在的本地項目中創建git BitBucket存儲庫 – 2015-07-02 13:08:23