Nokogiri install error

An error occurred while installing nokogiri (1.6.6.2), and Bundler cannot continue.
Make sure that `gem install nokogiri -v ‘1.6.6.2’` succeeds before bundling.

Well, this was a pain. I tried a lot of solutions such as;

rvm use system

rvm use 2.2.3 –default

Then a bunch of stack exchange solutions. But none of the solutions worked.

What did work

Simple… I got the idea from using the system’s installed version of ruby, but anyhow, since I wasn’t getting other weird El Capitan related errors, I did this, voila:

bundle config build.nokogiri –use-system-libraries