推到了heroku但没有改变app?
我使用以下三个命令将更改推送到现有应用程序,但更改未反映
$ git add . $ git commit -m "changes" # On branch master # Your branch is ahead of 'origin/master' by 2 commits. $ git push heroku master
我得到:
To git@heroku.com:sleepy-oasis-7771.git ! [rejected] master -> master (non-fast-forward) error: failed to push some refs to 'git@heroku.com:sleepy-oasis-7771.git' To prevent you from losing history, non-fast-forward updates were rejected Merge the remote changes (eg 'git pull') before pushing again. See the 'Note about fast-forwards' section of 'git push --help' for details.
并且应用程序中没有反映任何更改
你推了! [rejected]
! [rejected]
。 这就是为什么没有变化生效的原因。
如消息所示:
To prevent you from losing history, non-fast-forward updates were rejected Merge the remote changes (eg 'git pull') before pushing again. See the 'Note about fast-forwards' section of 'git push --help' for details.
这将引用您在本地计算机或在线上可见的更多文档。 同样,正如消息所示, git pull
(及其产生的合并)将解决此问题。
避免此问题的一种方法是使用rebase工作流而不是合并工作流。 在function分支中进行开发,当您准备好合并时,请拉出master,重新设置function分支,重新运行测试套件, 然后进行合并。
另外,请阅读您的错误消息。
- PG ::错误:错误:编码“UTF8”的无效字节序列:0xfc
- API请求 – OpenSSL :: SSL :: SSLError:SSL_connect SYSCALL返回= 5 errno = 0 state = SSLv3读取服务器hello A
- 无法通过Bundler安装gem。 远程:! 遥控器:遥控器:! 推送拒绝,无法编译Ruby app remote:
- git push heroku master失败“HTTP 400 curl 22请求的URL返回错误”
- 推送到Heroku时无法从远程存储库中读取(Rails教程5)
- 在没有自定义域的情况下,子域会话在Heroku上的Rails 2.3和Rails 3中不起作用?
- omniauth与facebook没有合作生产
- Heroku上用于登台服务器的不同robots.txt
- 使用BETWEEN时间戳的SQL查询的意外结果