【问题标题】:Cloud 9 Trouble getting on to the rails serverCloud 9 无法访问 rails 服务器
【发布时间】:2016-06-08 23:55:55
【问题描述】:

gemfile here 我是编码新手,无法连接到云 9 上的 rails 服务器。我不断收到此错误消息,如何解决此问题? ] !] 解析 Gemfile 时出错:Gemfile 的未定义局部变量或方法“资源”。 Bundler 无法继续。

# 来自 /home/ubuntu/workspace/blog/Gemfile:1 # -------------------------------------------

资源'https://rubygems.org'

【问题讨论】:

  • 在下面试试我的答案,如果仍然有错误,请告诉我。
  • 你应该试试source 而不是resource

标签: ruby-on-rails ide cloud9


【解决方案1】:

在您的 Gemfile 中,而不是:

resource 'https://rubygems.org'

应该是:

source 'https://rubygems.org'

【讨论】:

  • 那么,错误是一样的吗? Undefined local variable or method resource' 用于 Gemfile`
  • 更改 gemfile 后,您是否运行了 bundle install?
  • 是的,刚刚试过,我什么也没得到。仍然是错误消息
  • 那么,错误是什么?我不相信您仍然遇到上面发布的相同错误。
  • 很抱歉没有发布错误信息。这就是我不断收到的imgur.com/QsrMiUp
猜你喜欢
  • 1970-01-01
  • 2019-10-23
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2020-11-14
  • 1970-01-01
  • 2019-12-09
相关资源
最近更新 更多