4
votes

I'm using a gemset per project approach. Suppose I just installed RVM, created a gemset, called 'test' and install rails 3.1.0.rc4 there, which installs a bunch of gems. Now I switch to the global gemset (rvm gemset use global), and view my gems. I expect to see empty list, because I didn't install any gems into global gemset, but see all my gems from 'test' gemset. How is that?

My guess is that rvm gem list show all gems from all gemsets when invoked from global gemset. If so, how can I view only current gemset's gems?

3

3 Answers

7
votes

In common:

rvm <ruby version>@<gemset name> do gem list

For example:

rvm @test do gem list 

show that you want: gems on test gemset environment

Another way:

rvm use @test
gem list

show the same

2
votes

Use gem list instead of rvm gem list

1
votes

in RVM 1.16.0 the command gem is removed, it was causing to much confusion and was deprecated a year ago.

instead use:

rvm [<ruby>[@<gemset>],...|default|all] [--verbose] do <command> ...