Upgrading Rails (Isn't So Bad)

Upgrading Rails (Isn't So Bad)

Upgrading Rails gets a bad rap, but it doesn't have to be so daunting if we listen to our tools and remember that we're in control.

817f5f1ada5fdeffcd14668107c08f0a?s=128

Megan Tiu

June 29, 2016
Tweet

Transcript

  1. Upgrading Rails (Isn’t So Bad) Megan Tiu Rails Girls Atlanta

    June 29, 2016
  2. RailsConf

  3. It’s not so scary

  4. 0. Create a new branch

  5. $ git checkout -b rails5

  6. 1. Start with a clean test suite

  7. 1. Start with a clean test suite • No deprecation

    warnings • All tests passing • As many gems up-to-date as possible
  8. None
  9. 2. Bundle update

  10. $ bundle update rails

  11. 3. Don’t panic!

  12. None
  13. 4. Update the offending gem

  14. None
  15. gem ‘rspec-rails’, ~> ‘3.5.0.beta4’ # Gemfile

  16. $ bundle update rails rspec-rails

  17. 5. We’re still not panicking

  18. None
  19. None
  20. To GitHub!

  21. gem ‘exception_notification’, github: ‘smartinez87/exception_notification’, branch: ‘rails5’ # Gemfile

  22. $ bundle update rails rspec-rails exception_notification

  23. 6. !!!

  24. None
  25. Time to commit!

  26. 7. Make your tests pass

  27. None
  28. 8. Deprecation warnings, be gone!

  29. Use these...

  30. To achieve this!

  31. 9. Celebrate!

  32. None
  33. You are in control

  34. http://megantiu.com/blog/8/upgrading-rails- doesnt-have-to-be-painful

  35. https://speakerdeck.com/derekprior/keep- rails-upgraded