• Register
0 votes
105 views

Problem :

I am trying to execute the below script:

gem install rdoc --no-document

gem install bundle

bundle

 I have already added /srv/myuser/.gem/ruby/2.5.0/bin to the path so I was able to install the gems.

I can also find the bundle when I try to perform:

ls -ltrah /srv/myuser/.gem/ruby/2.5.0/bin

I have also tried to install the bundler but that is not helping the cause. Am I doing anything wrong here ?

The gem which bundle command is showing me nothing. The gem spec bundle command is showing it to me.

I also tried to install the bundler before running the bundle but the same issue as follows

“Can't find gem bundler (>= 0.a) with executable bundle (gem::gemnotfoundexception)”

 appears while executing below commands :

gem list bundle shows

bundle (0.0.1)
bundler (2.0.1)

 

Does anyone have any solution on my issue?

6 5 3
7,540 points

Please log in or register to answer this question.

1 Answer

0 votes

 Solution :

The Bundler version 2 have introduced the new feature to automatically use your version of Bundler which is specified in your Gemfile.lock of your project. So if you have the existing Gemfile.lock with the line like below at the bottom

BUNDLED WITH 1.17.3

Then the Bundler will try to run with the Bundler version < 2.0. Since you have just Bundler 2.0.1 (and the Rubygems >= 2.7.0) installed on your box, it is failing with the rather unhelpful error message.

To fix your issue, you must follow below approach :

·  You need to remove the lines from your Gemfile.lock and must use bundler 2.x everywhere from now on,

·   You can also try to install the bundler 1.x version with gem install bundler -v '< 2.0' to use your appropriate version as specified by the Gemfile.lock.

9 7 4
38,600 points

Related questions

1 vote
1 answer 3 views
3 views
Problem : I got this error when installing Rubygem : rubygems.rb:289:in `find_spec_for_exe': can't find gem bundler (>= 0.a) with executable bundle (Gem::GemNotFoundException) I have no idea what to do next ?
asked Mar 31 Shovo210 13.3k points
0 votes
1 answer 90 views
90 views
Problem: Hello Kodlogs, I tried pushing my app and I got an error message of this nature; you must use bundler 2 or greater with this lockfile. What can I do to correct this?
asked Nov 2, 2020 Festus James 380 points
0 votes
1 answer 732 views
732 views
Problem : I want to run the specs, you will need to install RSpec. First, run the gem install bundler in a root directory of the project. Then, run the bundle install. To run the single spec file, run the command like below: bundle exec rspec spec/00_hello_spec.rb. To ... ruby, and I want to bundle install inside of the atom? Could anyone tell me how to use the atom or run anything in the atom?
asked Jan 22, 2020 jwilliam 3.9k points
1 vote
1 answer 1 view
1 view
Problem : When launching this Guardfile : guard 'livereload' do watch(%r{.+\.(css|js|html)$}) end guard 'sass', :input => 'css', :style => :compressed, :extension => '.min.css' I got this Error : $ guard WARN: Unresolved specs during Gem::Specification.reset: lumberjack (>= 1.0.2) ffi (>= 0.5.0) WARN: Clearing out unresolved specs. Please report a bug if this causes problems. how do I fix this?
asked 3 days ago Shovo210 13.3k points
0 votes
1 answer 1 view
1 view
Problem: Run `bundle install` to install missing gems.I'm trying to install a Ruby based tool call Warvox and when I try to do a "make", I get the following error.Any advise/suggestions?
asked 1 day ago Humaira ahmed 9.6k points
0 votes
1 answer 2 views
2 views
Problem: Any thoughts or advice as to why am i getting the above error? Bundle install could not locate gemfile?
asked 5 days ago Sana8989 8.9k points
0 votes
1 answer 4 views
4 views
Problem: I'm trying to install a Ruby-based tool call Warvox and when I try to do a "make", I get the following error: Run `bundle install` to install missing gems. However ever after installing the missing gem, the error is still the same. Any advice/suggestions.
asked Mar 27 ummesalma 24.5k points
0 votes
1 answer 3 views
3 views
Problem: Please help me fix this dilemma &ldquo;Mkmf.rb can't find header files for ruby at /usr/share/include/ruby.h&rdquo;?
asked Apr 5 tuhin1 48.4k points
0 votes
1 answer 68 views
68 views
Problem: I am learning ruby and I have updated XCode on my Mac and since then when I run Docker using docker-sync-stack startI get the following error: mkmf.rb can't find header files for ruby at /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/ ... :, brew install rbenv ruby-buildbut that doesn't change anything. Does anyone have idea how I should fix this? I will be thankful!
asked Dec 2, 2020 sasha 16.2k points
0 votes
1 answer 86 views