我已经设置了一个Heroku应用程序,lucy-staging
:
Kurts-MacBook-Pro-2:lucy kurtpeek$ git remote -v
staging https://git.heroku.com/lucy-staging.git (fetch)
staging https://git.heroku.com/lucy-staging.git (push)
我有一个当地的分支机构custom-error-views
,我想把它推到master
遥控器的staging
分支。我试图通过使用命令https://devcenter.heroku.com/articles/multiple-environments#advanced-linking-local-branches-to-remote-apps跟随git push staging custom-error-views:master
,适用于推送Git子树:
Kurts-MacBook-Pro-2:lucy kurtpeek$ git subtree push staging custom-error-views:master --prefix lucy-web/
'custom-error-views:master' does not look like a ref
我不明白这个does not look like a ref
错误;它似乎类似于Heroku文档中的development:master
ref。任何人都可以指出这里有什么问题吗?
更新
从源代码(https://github.com/github/git-msysgit/blob/master/contrib/subtree/git-subtree.sh)可以看出,这个错误消息是专门针对git subtree
s抛出的。它减少了git check-ref-format
返回非零错误代码的事实:
Kurts-MacBook-Pro-2:lucy kurtpeek$ git check-ref-format custom-error-views:master
Kurts-MacBook-Pro-2:lucy kurtpeek$ echo $?
1