0

我已经尝试了很多方法来让 Administrate 捆绑,但我一直遇到问题,通常是围绕 activesupport gem。它似乎在寻找两个相互冲突的版本,否则我读错了。

“捆绑安装”后的错误:

Bundler could not find compatible versions for gem "activesupport":
In Gemfile:
actionpack was resolved to 4.0.13, which depends on
  activesupport (= 4.0.13)

actionpack was resolved to 4.0.13, which depends on
  activesupport (= 4.0.13)

actionpack was resolved to 4.0.13, which depends on
  activesupport (= 4.0.13)

administrate was resolved to 0.0.2, which depends on
  rails (~> 4.2) was resolved to 4.2.0, which depends on
    activesupport (= 4.2.0)

administrate was resolved to 0.0.2, which depends on
  rails (~> 4.2) was resolved to 4.2.0, which depends on
    activesupport (= 4.2.0)

我的宝石文件

# if RUBY_VERSION =~ /1.9/
#   Encoding.default_external = Encoding::UTF_8
#   Encoding.default_internal = Encoding::UTF_8
# end

source 'http://rubygems.org'
gem 'administrate'
gem 'activesupport'
gem 'actionpack'
gem 'activemodel'
gem 'cocoon','1.2.5'
gem 'ffi','1.9.6'
gem 'railties'
gem 'rails'
gem 'sass'
gem 'rubyzip', '0.9.9'
gem 'roo','1.12.1'
#gem 'mysql2', '0.3.11'
gem 'mysql2', '0.3.17'
gem 'jquery-rails', '2.2.1'
gem 'haml', '3.1.7'
gem "fog", '1.38.0'
# gem "fog-google", '0.4.1'
# gem 'google-api-client', '~> 0.8.6'
# gem 'puma'
gem 'thin', '1.7.0'
gem 'rake', '11.2.2'
gem 'tzinfo','0.3.51'

group :development do
  gem 'capistrano', '3.4.1'
  gem 'capistrano-rails', '1.3.0'
  gem 'capistrano-rvm', '0.1.2'
end
gem 'protected_attributes','1.1.3'
gem 'activerecord-session_store','1.0.0'
gem 'devise'
gem 'devise-async', '0.9.0'
gem 'cancan', '1.6.8'
gem 'simple_form', '3.0.4'
gem 'oauth', '0.5.1'
gem 'inherited_resources', '1.3.1'
gem 'will_paginate', '3.0.3'
gem 'bootstrap-will_paginate', '0.0.9'
gem 'mechanize', '2.5.1'
gem 'delayed_job', '4.0.6'
gem 'paperclip', '3.4.0'
gem 'spreadsheet', '0.6.4.1'
gem 'geocoder', '1.1.6'
gem 'whenever', '0.8.2', :require => false
gem 'american_date', '1.0.0'
gem 'money','5.1.1'
gem 'rets','0.10.1.20160503205231', path: '/var/rets'
gem 'httpclient','2.7.0'
gem 'haversine','0.3.0'
gem 'capybara','2.4.4'
gem 'poltergeist','1.6.0'
gem 'selenium-webdriver','2.35.1'
gem 'redis','3.2.0'
gem 'remote_lock','1.1.0'
gem 'bower-rails', '0.11.0'
gem 'sass-rails', '4.0.0'
gem 'jekyll', '3.3.0'
gem 'net-ssh'
gem 'angular_rails_csrf', '2.0.0'
gem 'newrelic_rpm', '3.18.1.330'

group :assets do
  gem 'stylus', '1.0.1'
  gem 'coffee-rails', '4.0.0'
  gem 'uglifier', '1.3.0'
end

group :development do
  # gem 'pry', '0.9.12.4'
  # gem 'pry-rails',  '0.3.4'
  # gem 'pry-remote', '0.1.8'
  # gem 'pry-stack_explorer', '0.4.9.1'
  gem 'pry-byebug','2.0.0'
  # gem 'pry-debugger', '0.2.3'
  # gem 'query_reviewer', :git => 'git://github.com/nesquena/query_reviewer.git'
  # gem 'bullet'
end

group :development, :test do
  gem 'rspec-rails', '~> 3.5'
end

gem 'elasticsearch-model', '0.1.9'
gem 'elasticsearch-rails', '0.1.9'

gem 'rest-client', '1.8.0'
gem 'doorkeeper', '3.1.0'
gem 'rack-cors', '0.4.0', :require => 'rack/cors'
gem 'dotenv-rails', '2.2.1', groups: [:development, :test]

我试过“捆绑更新”。我在 Ubuntu 环境中工作,使用最新版本的 ruby​​ (2.4.0)

4

1 回答 1

0

解决了。将 rails 限制为 4.2 版并将 gem i18n 添加到 Gemfile 允许打包程序完成

于 2017-09-05T01:37:35.677 回答