简体   繁体   English

找不到 gem 'rails (= 4.2.4) x64-mingw32'

[英]Could not find gem 'rails (= 4.2.4) x64-mingw32'

I was first developing my RoR application in Windows.我首先在 Windows 中开发我的 RoR 应用程序。 Now since I've been founding a few problems regarding some gems, SSH and stuff I decided to move to Linux.现在,由于我在一些 gem、SSH 和其他东西方面遇到了一些问题,因此我决定迁移到 Linux。 I am trying to initate the application, but It seems I am not able to.我正在尝试启动应用程序,但似乎我无法启动。

When I do bundle update rails I got the following error:当我执行bundle update rails ,出现以下错误:

Could not find gem 'rails (= 4.2.4) x64-mingw32' in the gems available on this
machine.

This is my tzinfo-data gem:这是我的 tzinfo-data gem:

gem 'tzinfo-data', platforms: [:mingw, :mswin, :jruby]

But I have already tried with this one too:但我也已经尝试过这个:

gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]

Any idea?任何的想法? Because when I just do bundle install I also got the following error:因为当我只执行bundle install我也收到以下错误:

You have requested:
  rails = 4.2.4

The bundle currently has rails locked at 4.2.4.
Try running `bundle update rails`

Update:更新:

Gemfile content Gemfile 内容

source 'https://rubygems.org'


# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '4.2.4'
# Use postgresql as the database for Active Record
gem 'pg'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 5.0'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'
# Use CoffeeScript for .coffee assets and views
gem 'coffee-rails', '~> 4.1.0'
# See https://github.com/rails/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby

gem 'bootstrap-sass', '~> 3.2.0'
gem 'autoprefixer-rails'

gem 'devise'

gem 'bootstrap_form'


# Use jquery as the JavaScript library
gem 'jquery-rails'
# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
gem 'turbolinks'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 2.0'
# bundle exec rake doc:rails generates the API under doc/api.
gem 'sdoc', '~> 0.4.0', group: :doc

# Use ActiveModel has_secure_password
gem "bcrypt-ruby", '~> 3.0.0'

gem 'google-api-client', '0.9'

gem 'letsrate'

gem 'will_paginate', '~> 3.0.6'

gem 'filterrific'

#gem 'ratyrate'

# Use Unicorn as the app server
# gem 'unicorn'

# Use Capistrano for deployment
# gem 'capistrano-rails', group: :development

group :development, :test do
  # Call 'byebug' anywhere in the code to stop execution and get a debugger console
  gem 'byebug'
end

group :development do
  # Access an IRB console on exception pages or by using <%= console %> in views
  gem 'web-console', '~> 2.0'
end

# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: [:mingw, :mswin, :jruby]

If you've installed Rails using bundler and rubygems, make sure you have the latest version in your Gemfile:如果您已经使用 bundler 和 ruby​​gems 安装了 Rails,请确保您的 Gemfile 中有最新版本:

rails '4.2.4'

there is Gemfile.lock which locks the version.有 Gemfile.lock 可以锁定版本。 You delete that and run again bundle install.您删除它并再次运行 bundle install。 it will work.它会起作用。

bundle install
  1. Visit https://rubygems.org/gems访问https://rubygems.org/gems
  2. Search for your gem.搜索您的宝石。 Once found, copy the text from the box titled GEMFILE找到后,从标题为GEMFILE的框中复制文本
  3. Add the copied text in your Gemfile found inside your app在您的应用程序中找到的Gemfile添加复制的文本
  4. Run bundle from the console opened at the root of your app.从在应用程序根目录打开的控制台运行bundle

On successful installation of the gems your console will display the message: Bundle complete! xx Gemfile dependencies, xx gems now installed.成功安装 gems 后,您的控制台将显示消息: Bundle complete! xx Gemfile dependencies, xx gems now installed. Bundle complete! xx Gemfile dependencies, xx gems now installed.

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 找不到在轨道上运行服务器ruby的gem&#39;byebug x64-mingw32&#39;吗? - Could not find gem 'byebug x64-mingw32' for run server ruby on rails? 红宝石宝石错误:找不到宝石&#39;logstash-devutils(&gt; = 0)x64-mingw32&#39; - ruby gem error: Could not find gem 'logstash-devutils (>= 0) x64-mingw32' 在 Gemfile 中列出的任何 gem 源中找不到 gem 'puma (= 3.9.1) x64-mingw32' - Could not find gem 'puma (= 3.9.1) x64-mingw32' in any of the gem sources listed in your Gemfile 在本地安装的 gem 中找不到 gem &#39;pg x64-mingw32&#39; - Could not find gem 'pg x64-mingw32' in locally installed gems 找不到gem&#39;rails x86-mingw32&#39; - Could not find gem 'rails x86-mingw32' 无法运行Rails服务器,找不到Gem&#39;rail(4.2.5.1)x86-mingw32&#39; - Can't Run Rails Server, Could Not Find Gem 'rails(4.2.5.1) x86-mingw32' 运行 rails 服务器时找不到 gem &#39;rails (= 4.2.5) x86-mingw32&#39; - Could not find gem 'rails (= 4.2.5) x86-mingw32' when running rails server Bundler 找不到 gem “rails” 的兼容版本 | 在 Gemfile 中:rails (~&gt; 6.1.0) x64-mingw3 - Bundler could not find compatible versions for gem “rails” | In Gemfile: rails (~> 6.1.0) x64-mingw3 安装mysql2 ruby​​ 2.2.1p85(2015-02-26修订版49769)[x64-mingw32] rails 4.2.1时发生错误 - Error in installing mysql2 ruby 2.2.1p85 (2015-02-26 revision 49769) [x64-mingw32] rails 4.2.1 找不到宝石squlite x64 ming32 - Could not find gem squlite x64 ming32
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM