Gems not found by 'gem list' when using 'bundle install' for git gems with RVM
I believe the cause of the issue is that bundler is installing the git gem into .rvm/gems/ruby-1.9.3-p194@something/bundler/gems while all other gems are installed into .rvm/gems/ruby-1.9.3-p194@something/gems. As a result, ‘bundle list’ shows the gem but ‘gem list’ does not.
Any thoughts here? I’d really prefer not to use bundle to execute everything.
One Solution collect form web for “Gems not found by 'gem list' when using 'bundle install' for git gems with RVM”
Bundler is for bundling gems with applications. It doesn’t make sense to use it for system gems. Unfortunately, the non-bundler gem system offers no direct way to install git-based gems (I actually asked a question about this previously, see Is it possible to directly install a gem from a git repository?). Instead, you have to do it manually in three steps:
Clone the gem repo (this is assuming a github repository, but it will work for a repository hosted anywhere, just substitute the right git repo location).
git clone git://github.com/user/gem.git
Go to the cloned gem repo directory and build the gem (this will also check for dependencies and warn you if the install failed because of a missing dependency — in that case just install the dependencies and try again).
Or if that doesn’t work:
gem build gem.gemspec
This should have created a file with a name like
pkg/gem-1.2.3.gem(sometimes it will build in the
pkgdirectory like this, sometimes it will build in the gem repo root directory). You can now install it.
gem install pkg/gem-1.2.3.gem