Similar to npm add module --save to add a node package to the package.json file, you can use bundle to download, install and save a gem to the Gemfile.
npm add module --save
bundle add {gem} {version}
# examples bundle add pdf-reader "2.4" bundle add pdf-reader
Have a Gemfile or a Gemfile.lock and want to see what versions are installed.
gem list
Specify a specific ruby gem file to use, typically development and local, instead of the default installed version.
gem "foo", :path => "/path/to/foo"