bsbzyq
5.775K
· August 2013 ·
1306cb3c1c4be568ca087de48bc0d967

Must have development Rails gems

TL;DR

better_errors, jazz_hands, bullet, quiet_assets, rack-mini-profiler, terminal-notifier-guard, figaro

About me

First things first - I'm a Rails newbie. I've been messing with it for about 6 months and I've been to this years RailsConf as a scholarship recipient. I've written a couple of Rails apps and I'm just diving into TDD and BDD since I've never done tests before.

The gems

better_errors

Seriously can't develop without this one anymore. It replaces the standard Rails error page with a much better and more useful error page. You should also install binding_of_caller which gives you REPL and local/instance variable inspection which is just awesome. You can also use it with Pry, just put this in your development.rb initializer:

BetterErrors.use_pry!
AwesomePrint.defaults = { plain: true }

jazz_hands

Now this is a collection gem - it includes many many many sweet gems:

  • Pry for a powerful shell alternative to IRB.
  • Awesome Print for stylish pretty print.
  • Hirb for tabular collection output.
  • Pry Rails for additional commands (show-routes, show-models, show-middleware) in the Rails console.
  • Pry Doc to browse Ruby source, including C, directly from the console.
  • Pry Git to teach the console about git. Diffs, blames, and commits on methods and classes, not just files.
  • Pry Remote to connect remotely to a Pry console.
  • Pry Debugger to turn the console into a simple debugger.
  • Pry Stack Explorer to navigate the call stack and frames.
  • Coolline and Coderay for syntax highlighting as you type.

bullet

Now this is a very simple gem, that looks at your queries. Whenever you do a N+1 it'll log it and optionally alert you. There are many ways it can report to you, just read the README.

quiet_assets

Nothing more annoying that those assets requests spam messages in Rails log. This shuts it off.

rack-mini-profiler

It's a middleware that displays speed badge for every page. It shows a nice sidebar with all the DB requests and timings and such. Useful for identifying bottlenecks.

terminal-notifier-guard

Adds native notifications to Guard. Only useful if you use Guard and are on Mac OS 10.8+

figaro

It's the best Rails configuration gem I came across. It provides a clean and simple way to configure your app and keep the private stuff private. This way you can easily open source projects without worrying about secret tokens and such. The best of all? It knows how to export those ENV vars to Heroku.

Got more?

Do comment :)

Sign in or sign up to add your response.

5 Responses

8586
Photo on 2012 07 30 at 18.13

I also like adding the Sentry gem to keep track of dev and production bugs.

gem 'sentry-raven'
over 1 year ago ·
8592
4693d7cfa88635d430c0de9a92f8dd84

Thanks for sharing!
I like to use this one for easier deployment to heroku:

gem 'rails_12factor', group: :production
over 1 year ago ·
8818
2c28c25c8a4a035bdda63057d99ff188

Nice post. Thanks.

over 1 year ago ·
11069
729f685b8e8d7e9feed18c177c82e59b

If you are dealing with i18n: https://github.com/glebm/i18n-tasks

over 1 year ago ·
16100
C308514554112d4aba422a6132ce1515