5
Pry Open Rails A better way of debugging + Chris McIntyre Hosted by theFirehoseProject

Lightning talk 9.10.15

Embed Size (px)

Citation preview

Pry Open RailsA better way of debugging

+

Chris McIntyre

Hosted by theFirehoseProject

What is Pry?repl- Read Evaluate Print Looppass a script: loop {p eval gets}IRB with superpowers debugger, command system, gist integrator, and much more!

Lets Install$ gem install pry pry-doc --no-ri --no-rdocGemfile - gem pry, group: :development$ bundle install$ pry -r ./config/environment$ rails c then manually enter with $ pry ORpry as default - config/environment/development

Start Prying Away in Rails App$ rails cpry(main)> help for list of commandspry(main)> cd into-a-classpry()> first (or some other class method)and so much more

Make squashing bugs bearable maybe even enjoyable - use PryLearn more http://railscasts.com/episodes/280-pry-with-railsJosh Cheek pry intro: https://vimeo.com/26391171http://pryrepl.org/