I am trying to install sass on my mac, but every time I try to use any gem command like gem install sass or gem update --system I get the following errors:

/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- rubygems/core_ext/kernel_warn (LoadError)
from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /Library/Ruby/Site/2.3.0/rubygems.rb:1395:in `<top (required)>'
from <internal:gem_prelude>:4:in `require'
from <internal:gem_prelude>:4:in `<internal:gem_prelude>'

This also happens when I try to install homebrew.

My ruby version using ruby -v gives

ruby 2.3.7p456 (2018-03-28 revision 63024) [universal.x86_64-darwin18]

I am using macOS 10.14.2.

Why am I getting this error, and how do I fix it?



Ok I found a short term solution


Installing rvm and doing this above worked for me.

My usr/bin/ruby is still not working, so I would assume isn't a full fix for the system ruby. ruby works for me now. I wasn't able to install brew before, but now I am able to.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.