Gem installs can be slooow. One of the biggest culprits is documentation. Every time you install a gem, your computer has to scan the source of that gem and generate documentation.

This can be useful if you often need to check gem documentation when you're offline. Just run  gem server and point your browser at http://localhost:8808 to access them. The ri command is also handy to search documentation from the terminal.

But if you're like me, you probably don't use local docs. You probably have a decent internet connection at most times. So the time spent generating documentation is just time wasted.

If you're using bundler to install all of your gems, you don't have to do anything. Bundler skips rdoc/ri by default. If you happen to be using the gem command directly, you'll need to do a bit of configuration.

You may already know that you can disable rdoc/ri generation when you run gem install, by passing in certain flags.

gem install honeybadger --no-rdoc --no-ri  # The old, deprecated way
gem install honeybadger --no-document      # The new way

You can also tell rubygems to apply these flags as defaults. Just add the following line to your ~/.gemrc file:

gem: --no-document

But what if you're planning a camping trip and need to grab the local documentation? It's no problem to generate it yourself.

gem rdoc --all --overwrite # regen all docs
gem rdoc honeybadger # generate docs for one gem

Be careful if you choose to regen all your docs, though. It might take a while. :)

Get the Honeybadger newsletter

Each month we share news, best practices, and stories from the DevOps & monitoring community—exclusively for developers like you.
    author photo
    Starr Horne

    Starr Horne is a Rubyist and Chief JavaScripter at Honeybadger.io. When she's not neck-deep in other people's bugs, she enjoys making furniture with traditional hand-tools, reading history and brewing beer in her garage in Seattle.

    More articles by Starr Horne
    An advertisement for Honeybadger that reads 'Turn your logs into events.'

    "Splunk-like querying without having to sell my kidneys? nice"

    That’s a direct quote from someone who just saw Honeybadger Insights. It’s a bit like Papertrail or DataDog—but with just the good parts and a reasonable price tag.

    Best of all, Insights logging is available on our free tier as part of a comprehensive monitoring suite including error tracking, uptime monitoring, status pages, and more.

    Start logging for FREE
    Simple 5-minute setup — No credit card required