【问题标题】:Bundler could not find compatible versions for gem "spring"Bundler 找不到 gem "spring" 的兼容版本
【发布时间】:2017-07-17 19:39:44
【问题描述】:

在云 9 上运行 bundle install --without production 后,这是我得到的错误:

The dependency tzinfo-data (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for x86-mingw32, x86-mswin32, x64-mingw32, java. To add those platforms to the bundle, run `bundle lock --add-platform x86-mingw32 x86-mswin32 x64-mingw32 java`.
Fetching dependency metadata from https://rubygems.org/.
Resolving dependencies...
Bundler could not find compatible versions for gem "spring":
  In snapshot (Gemfile.lock):
    spring (= 2.0.1)

  In Gemfile:
    spring

    spring-watcher-listen (= 2.0.0) was resolved to 2.0.0, which depends on
      spring (~> 1.2)

Running `bundle update` will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.

请提供帮助。

【问题讨论】:

    标签: ruby-on-rails ruby rubygems gemfile cloud9


    【解决方案1】:

    “spring-watch-listen”的 gem 版本为 2.0.0。由于依赖性问题,这会阻止您捆绑您的 gem 库。尝试更改 Gemfile 中的版本指令。只需删除逗号后的数字即可。

     #/path/to/project/Gemfile
     gem 'spring-watch-listen', '2.0.0'
    

    保存文件后,从应用程序根目录中的 linux 终端运行此命令。

      bundle install
    

    如果这不起作用,您可以尝试从应用程序的根目录运行以下命令。

     bundle update
    

    【讨论】:

      猜你喜欢
      • 2011-10-31
      • 2018-02-09
      • 2014-05-26
      • 2014-03-14
      • 2013-03-13
      • 2019-05-07
      • 2016-02-17
      • 2013-03-12
      • 2012-04-08
      相关资源
      最近更新 更多