我在heroku上创建了一个PHP应用程序,并安装了sendgrid-php子模块。但是,当我尝试推送时,会发生这种情况:
$ git push heroku
Counting objects: 5, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 289 bytes, done.
Total 3 (delta 2), reused 0 (delta 0)
-----> Git submodules detected, installing
Submodule 'sendgrid-php' (https://github.com/sendgrid/sendgrid-php) registered for path 'sendgrid-php'
warning: templates not found /app/vendor/share/git-core/templates
Initialized empty Git repository in /tmp/build_wfcgkfb0p50x/sendgrid-php/.git/
fatal: reference is not a tree: 3f145137608a98b09eb01d447ff9d31d161ef2a2
Unable to checkout '3f145137608a98b09eb01d447ff9d31d161ef2a2' in submodule path 'sendgrid-php'
! Heroku push rejected, Submodule install failed with exit code 1
To git@heroku.com:gausschain.git
! [remote rejected] master -> master (pre-receive hook declined)
我还为Heroku配置了SendGrid插件。关于如何解决这个问题的任何想法?
答案 0 :(得分:3)
这意味着在实际的子模块中
SHA1 - 3f145137608a98b09eb01d447ff9d31d161ef2a2
尚未推出。但在.gitmodules文件中,此SHA记录在该特定分支
上答案 1 :(得分:1)
听起来像你实际上做错了什么。安装SendGrid PHP库的推荐方法是使用composer。您应该查看自述文件,了解有关执行此操作的详细信息。
有一个PHP Heroku Buildpack,它有作曲家支持。这是一个帮助您入门的教程: