RailsアプリでRubyのバージョンを2.0.0から2.3.0にあげたところ、Rakeコマンドが使えなくなりました。2.3.0でのみエラーが発生します。
おそらく、パス関連がしっかり設定されていないと思うっているのですが、設定方法が検索してもよくわかりませんでしたので、こちらに投稿させていただきました。
rake routes rake aborted! LoadError: cannot load such file -- bundler/setup /Users/username/test_app/config/boot.rb:3:in `<top (required)>' /Users/username/test_app/config/application.rb:1:in `<top (required)>' /Users/username/test_app/Rakefile:4:in `<top (required)>' (See full trace by running task with --trace)
ruby -v ruby 2.3.0p0 (2015-12-25 revision 53290) [x86_64-darwin15]
rails -v Rails 4.2.4
bundle -v Bundler version 1.12.4
test_app username$ gem env RubyGems Environment: - RUBYGEMS VERSION: 2.5.1 - RUBY VERSION: 2.3.0 (2015-12-25 patchlevel 0) [x86_64-darwin15] - INSTALLATION DIRECTORY: /Users/username/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0 - USER INSTALLATION DIRECTORY: /Users/username/.gem/ruby/2.3.0 - RUBY EXECUTABLE: /Users/username/.rbenv/versions/2.3.0/bin/ruby - EXECUTABLE DIRECTORY: /Users/username/.rbenv/versions/2.3.0/bin - SPEC CACHE DIRECTORY: /Users/username/.gem/specs - SYSTEM CONFIGURATION DIRECTORY: /Users/username/.rbenv/versions/2.3.0/etc - RUBYGEMS PLATFORMS: - ruby - x86_64-darwin-15 - GEM PATHS: - /Users/username/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0 - /Users/username/.gem/ruby/2.3.0 - GEM CONFIGURATION: - :update_sources => true - :verbose => true - :backtrace => false - :bulk_threshold => 1000 - REMOTE SOURCES: - https://rubygems.org/ - SHELL PATH: - /Users/username/.rbenv/versions/2.3.0/bin - /usr/local/Cellar/rbenv/1.0.0/libexec - /Users/username/.rbenv/shims - /usr/local/bin - /usr/bin - /bin - /usr/sbin - /sbin - /opt/X11/bin
config/boot.rb ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) require 'bundler/setup' # Set up gems listed in the Gemfile.
config/application.rb require File.expand_path('../boot', __FILE__) require 'rails/all' # Require the gems listed in Gemfile, including any gems # you've limited to :test, :development, or :production. Bundler.require(*Rails.groups) module TestApp class Application < Rails::Application config.active_record.raise_in_transactional_callbacks = true end end
Rakefile # Add your own tasks in files placed in lib/tasks ending in .rake, # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. require File.expand_path('../config/application', __FILE__) Rails.application.load_tasks
関連しそうな情報を載せてみましたが、他に必要情報ありましたら、すぐに修正しますのでお手数ですが知らせてもらえたら嬉しいです。。。。
ご教授願います。
`gem list` もあるとよいかと。あと、rubyバージョンアップ後にアプリケーションのホームで行った操作のリストも。