mean.io 推送到 git 仓库

9

我使用mean.io创建了一个基于MEAN堆栈的项目。

mean init

这创建了一个git仓库,我想将其推送到Bitbucket上的自己的私有git仓库中。我执行了以下操作:
git remote add origin git@bitbucket.org:my_login/reponame.git
git push -u origin --all

我遇到了以下错误。
! [remote rejected] master -> master (shallow update not allowed)

有什么建议,我如何将本地repo推送到全新的Bitbucket远程repo?
2个回答

12
git fetch --unshallow upstream

那么

git push -u origin --all

“git fetch --unshallow upstream” 是我需要的,但在文档中找不到。谢谢! - Alexey
这个方法可以帮助解决来自Bitbucket的以下错误:! [remote rejected] master -> master (missing necessary objects) - 谢谢! - hooke

1

我得到了这个错误: 错误:--all不能与refspecs组合使用。 - Methuz Kaewsai-kao

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接