0
我在與rails
和coffee-rails
一些不兼容的問題:軌道4 - 捆紮機找不到兼容版本的寶石 「railties」
Bundler could not find compatible versions for gem "railties":
In Gemfile:
rails (= 4.0.0) x86-mingw32 depends on
railties (= 4.0.0) x86-mingw32
coffee-rails (= 4.0.0) x86-mingw32 depends on
railties (4.0.1)
這裏是我的Gemfile:
source 'https://rubygems.org'
ruby '2.0.0'
# Version required for this application
gem 'rails', '4.0.0' # Rails framework
gem 'bootstrap-sass', '2.3.2.0' # Used for advanced CSS: open-source Sass add on from Twitter
gem 'bcrypt-ruby', '3.0.1' # Used for password encryption
gem 'pg', '0.15.1' # Used for connection to Postgres
gem 'jquery-ui-rails' # Used to create user interfaces
gem 'crypt' # Used for message encryption
gem 'http_parser.rb', '0.6.0.beta.2' # EM-Websocket dependancy
gem 'eventmachine' # EM-Websocket dependancy
group :assets do
gem 'haml_coffee_assets' # Used for Coffescript template generation
gem 'execjs' # Javascript helper
end
group :development, :test do # Groups define the environment in which the Gem will be needed
gem 'rspec-rails', '2.13.1' # Used for testing/TDD
gem 'guard-rspec', '2.5.0' # Used for automated RSpec testing
end
group :test do # Used within the test environment
gem 'selenium-webdriver', '2.0.0' # Used with RSpec to create automated tests
gem 'capybara', '2.1.0' # Adds more natural syntax to RSpec test scripts, and allows webpage tests
gem 'libnotify', '0.8.0' # Automatic notifications of Guard RSpec test results
gem 'spork-rails' # Used to speed up testing
gem 'guard-spork', '1.5.0' # Required for Guard/Spork compatibility: autostarts a Spork server with Guard
gem 'childprocess', '0.3.6' # Controls external programs
gem 'factory_girl_rails', '4.2.1' # Used mainly for testing Model management
end
gem 'sass-rails', '4.0.0' # Advanced CSS styling
gem 'uglifier', '2.1.1' # minifies Javascript code
gem 'coffee-rails', '4.0.0' # Allows CoffeeScript to adapt to the Assets pipeline
gem 'coffee-script-source', '1.5.0'
gem 'jquery-rails', '2.2.1' # Advanced Javascript functions: added ease of use
gem 'turbolinks', '1.1.1' # Makes following links faster: uses Assets pipeline
gem 'jbuilder', '1.0.2' # Creates JSON structures
group :doc do # required gem
gem 'sdoc', '0.3.20', require: false
end
group :production do # used only within deployment
gem 'rails_12factor', '0.0.2'
end
而且gem list railties
顯示:
PS C:\Users\HP\Ubuntu One\A2 Computing Project\Software Development\Client> gem list railties
*** LOCAL GEMS ***
railties (4.0.1, 4.0.0)
對上一個問題的回答我發現說,運行gem install railties
修復了它,但它並沒有爲我。任何幫助?
這似乎是一個WINDOWS問題。 Bundler似乎在抱怨沒有安裝Windows版本的railties,但它沒有安裝它。在我的情況下,提到的railties的版本實際上是在gems文件夾中的,所以它必須是它們不是WINDOWS版本。換句話說,錯誤信息並沒有充分解釋問題的真正含義。 – Peter
Bundler無法找到適用於gem「railties」的兼容版本: In Gemfile: coffee-rails(〜> 3.2.1)x86-mingw32被解析爲3.2.2,這取決於 railties(〜> 3.2.0) x86-mingw32 rails(= 4.2.5.1)x86-mingw32被解析爲4.2.5.1,這取決於 railties(= 4.2.5.1)x86-mingw32 – Peter