Share your favorite/useful gems!

Learning which gems to use has always lead to a couple hours of scouring github, or other blogs to find out which ones are most useful. I’d like to see which ones you use and how they’re useful. I’ll start with one:

“Did You Mean?” GEM. This bad boy is great for correcting misspelled methods or classes. Great for beginners to use in your test/production environment. It’s sort of like linting for Ruby, but for run-time fixes.
http://www.yukinishijima.net/2014/10/21/did-you-mean-experience-in-ruby.html

I’ve really enjoyed using attr_extras: GitHub - barsoom/attr_extras: Takes some boilerplate out of Ruby with methods like attr_initialize.

From their readme:

Instead of

class InvoiceBuilder
  def initialize(invoice, employee)
    @invoice = invoice
    @employee = employee
  end

  private

  attr_reader :invoice, :employee
end

you can just do

class InvoiceBuilder
  pattr_initialize :invoice, :employee
end

I’ve enjoyed the convenience of seed_migrations, which creates a concept of data migrations you can use to separate modifying the structure of your database from setting up reference data or converting existing data. You can tie running data migrations to running schema migrations, or run them separately.

Wow that’s super useful for my workflow! Thanks for that Ben!

Really convenient Geoff! I think I’ll try this on my current project