Heroku部署错误

编程入门 行业动态 更新时间:2024-10-28 11:32:15
本文介绍了Heroku部署错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

$ b

C:/Reduce/lib/ruby/在Windows环境中,出现以下错误: gems / 1.8 / gems / heroku-1.9.13 / lib / heroku / commands / base.rb:32: ':没有这样的文件或目录 - git remote(Errno :: ENOENT) from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/commands/ba se.rb:32 :在 shell' from C:/Ruby/lib/ruby/1.8/fileutils.rb:121:in chdir'从C:/Ruby/lib/ruby/1.8/fileutils.rb:121:在 cd' from C:/Ruby/lib/ruby/gems/1.8/gems /heroku-1.9.13/lib/heroku/commands/ba se.rb:32:在 shell' from C:/ Ruby / lib / ruby​​ / gems / 1.8 / gems / heroku-1.9.13 / lib / heroku / commands / ap p.rb:52:在从C:/ Ruby / lib / ruby​​ / gems / 1.8 / gems / heroku-1.9.13 / lib / heroku / command.rb: 48:在从C:/ Ruby / lib / ruby​​ /宝石/ 1.8 /宝石/ Heroku的-1.9.13 / lib / heroku / command.rb: 48:在 run_internal' from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib /heroku/command.rb: 20:在从C运行':/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/bin / heroku:13 C:/ Ruby / bin / heroku中的:19:在load中从C:/ Ruby / bin / heroku:19

任何想法我可以改正这一点?这是从Ruby命令行运行的(在我看来,像普通命令行一样)

解决方案

好的,我想通了一种使它工作的方式以及它可能发生的原因。

出于某种原因,我只能从CMD提示符运行Ruby命令,但GIT命令似乎只能工作来自GIT Bash。在GIT Bash中,Ruby命令不起作用。

当您运行Heroku命令创建服务时,它似乎想要运行某些GIT命令, t以CMD提示符的方式工作。

为了解决这个问题,我现在手动将GIT的Heroku路径添加为远程,然后在需要时手动推动。一个额外的步骤,但一切仍然按预期工作。

如果您需要帮助工作,请查看此链接中的信息: www.wiki.devchix/index.php?title=Working_around_the_%22heroku_create%22_error

In a windows environment I am getting the following error when trying to deploy to Heroku

C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/commands/base.rb:32:in ': No such file or directory - git remote (Errno::ENOENT) from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/commands/ba se.rb:32:in shell' from C:/Ruby/lib/ruby/1.8/fileutils.rb:121:in chdir' from C:/Ruby/lib/ruby/1.8/fileutils.rb:121:in cd' from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/commands/ba se.rb:32:inshell' from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/commands/ap p.rb:52:in create' from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/command.rb: 48:insend' from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/command.rb: 48:in run_internal' from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/lib/heroku/command.rb: 20:inrun' from C:/Ruby/lib/ruby/gems/1.8/gems/heroku-1.9.13/bin/heroku:13 from C:/Ruby/bin/heroku:19:in `load' from C:/Ruby/bin/heroku:19

Any idea how I can correct this? This is being run from the Ruby Command line (which seems to me like the regular command line)

解决方案

Ok so I figured out a way to make it work and why it is likely happening.

For some reason I can only run the Ruby commands from the CMD prompt however the GIT commands only seem to work from the GIT Bash. When in the GIT Bash the Ruby commands don't work.

When you run the Heroku commands to create the service it seems to want to run certain GIT commands which don't work from the CMD prompt the way I have it set up.

To get around this for the moment I am adding the Heroku path for GIT as a remote manually and then pushing that manually when needed. An extra step but everything still works as intended.

If you need help with the work around check out the information in this link: www.wiki.devchix/index.php?title=Working_around_the_%22heroku_create%22_error

更多推荐

Heroku部署错误

本文发布于:2023-10-28 02:15:16,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1535210.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:错误   Heroku

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!