RVM and Gemset

 GemSet- gemset is just a container you can use to keep gems separate from each other. Creating a gemset per project allows you to change gems (and gem versions) for one project without breaking all your other projects. Each project need only worry about its own gems.


RVM-

RVM is a command-line tool for managing multiple ruby versions and also uses a separate gemset for each rails app.

Why we need RVM

How RVM works:

/home/user/.rvm/rubies/ruby-2.4.1/bin/ruby
/home/user/.rvm/rubies/ruby-2.6.3/bin/ruby

How to install and use RVM in Ubuntu:

$ \curl -sSL https://get.rvm.io | bash -s stable

$ rvm install 2.4.1
$ rvm use — create 2.4.1@rtl_shop

$ rvm use 2.4.1@rtl_shop

RVM supports .ruby-version and .ruby-gemset:

2.4.1
rtl_shop

RVM Alternatives:


Comments