So, you are using the e text editor and try to run a bundle only to be confronted with the following:

ruby: no such file to load – ubygems (LoadError) ruby: no such file to load – ubygems (LoadError)

After doing some digging it turns out the cause is the RUBYOPT=-rubygems environment variable that is set by the Windows one-click Ruby installer. Now, if you have not got rubygems installed you might be able to get away with simply unsetting the RUBYOPT environment variable (although YMMV).

However, as e text editor makes use of Ruby via Cygwin, another solution is to modify your .bashrc file:

Try this:

Go to the cygwin bash prompt.  If you don't know how to get there, use Start -> Run -> c:\cygwin\cygwin.bat.

echo unset RUBYOPT >> .bashrc

. .bashrc


If you see:

You should be good to go.

But what worked for me - and I don’t know whether this has anything to do with me having Ruby installed under Windows and under Cygwin - was making the same changes to .bashrc outlined above to my .profile script (so simply replace .bashrc with .profile in the quoted text above).

Hopefully at least one of these methods should work for you.