Use bundle to add gems to Gemfile

Snippet

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.

bundle add {gem} {version}
# examples
bundle add pdf-reader "2.4"
 
bundle add pdf-reader 

Add new comment

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.