当我使用
将angular-fullstack应用程序部署到heroku时grunt buildcontrol:heroku 命令,获得以下警告
警告:致命:' heroku'似乎不是一个git存储库 致命的:无法从远程存储库读取。
请确保您拥有正确的访问权限 并且存储库存在。 使用--force继续。
我可以访问存储库
答案 0 :(得分:0)
最后,通过查看grunt构建控件文档(Django Rest framework),我得到了问题的解决方案。
Grunt构建控件使用其远程URL将代码推送到heroku远程存储库。
在grunt文件中,我添加了远程URL而不是远程名称(如下所示):
buildcontrol: {
options: {
dir: '<%= yeoman.dist %>',
commit: true,
push: true,
connectCommits: false,
message: 'Built %sourceName% from commit %sourceCommit% on branch %sourceBranch%',
},
staging: {
options: {
remote: 'https://git.heroku.com/myapp-staging.git',
branch: 'staging',
remoteBranch: 'master'
}
}
}