vertiginous / pik

Ruby version manager for Windows
830 stars 122 forks source link

pik and gems #122

Open PandaWood opened 12 years ago

PandaWood commented 12 years ago

I'm not sure what's going on here but it seems to me that pik doesn't set or use the gem_path properly or something? I'm using GitBash. Basically, no matter what or how many gems I install, after switching to a certain RVM (1.9.1) with pik, they are basically not installed.

pik use 191 pik list *191: ruby 1.9.1p378 (2010-01-10 revision 26273) [i386-mingw32] 192: ruby 1.9.2p290 (2011-07-09) [i386-mingw32] gem install bundler -v =1.0.3 successfully installed bundler-1.0.3

gem list * LOCAL GEMS *

It's not installed. No matter how many gems I install, gem list, shows nothing. To install pik, I did the "gem install" and followed the instructions, as of yesterday (ie latest version)

jfabre commented 12 years ago

I've got the exact same problem with git bash. It is stuck at version 192 for me and everything works fine until I execute pik use or pik sw. Then I lose all my gems.

If I use normal command line seems like everything works fine.

Even if I change the ruby version in command line it does not get applied in git bash.

Here is what I receive if I try to use rake under bundler

bundle exec rake -T c:/Ruby/lib/ruby/1.9.1/rubygems.rb:762:in report_activate_error': Could not find Rub yGem bundler (>= 0) (Gem::LoadError) from c:/Ruby/lib/ruby/1.9.1/rubygems.rb:219:inactivate' from c:/Ruby/lib/ruby/1.9.1/rubygems.rb:1065:in gem' from c:/Ruby187/bin/bundle:18:in

'

Hope this helps.

jasonkarns commented 12 years ago

I've got the same problem. Scenario: jruby 1.6.5 is my default

And here's my gem environment when executed from /c/ruby192/bin (executed against ruby 192 without using pik). RubyGems Environment:

Here's my gem environment when executed after pik switch ruby 1.9.2 RubyGems Environment:

Notice that after using pik, the INSTALLATION DIRECTORY is blank. The EXECUTABLE DIRECTORY is different (/bin instead of /c/jruby192/bin). And GEM PATHS is blank.

jasonkarns commented 12 years ago

It looks like this may be a duplicate of Issue #63.

jwebcat commented 11 years ago

This happened for me as well I applied the fix from the issue # 63 to my .pikrc file and voila' :dancers:

https://github.com/vertiginous/pik/issues/63