Ruby: How to install a specific version of a ruby gem?

Using the command-line gem tool, how can I install a specific version of a gem?

7 s
7

Use the -v flag:

$ gem install fog -v 1.8

Leave a Comment