Take the 2-minute tour ×

I don't see a way of just going to the next line when using pry as a debugger. All I can find is to edit the method and move binding.pry to the next line. Is there such a feature?

22:     def scan path
23:         @last_line_had_text, @files_read, @hands_read = nil, 0, 0
24:         Find.find(path){ |file_name|
=> 25:          binding.pry
26:             read_file(file_name) if file_name.include?(".txt")
27:         }
28:     end
share|improve this question
Pry isn't a debugger. –  Dave Newton Oct 19 '11 at 22:09
see this answer for a more current solution: stackoverflow.com/a/16698615/1396904 –  andorov Nov 20 '13 at 3:33
add comment

5 Answers

up vote 5 down vote accepted

If you want (this and more) debugging features you'll need to use pry_debug: https://github.com/Mon-Ouie/pry_debug

share|improve this answer
Ah; I was hoping somebody would do this--it was a pain flopping bck and forth between ruby-debug and pry; cool. –  Dave Newton Oct 19 '11 at 22:10
@Dave Newton, you may also like the ruby-debug_pry project linked in my answer below –  banister Oct 20 '11 at 0:31
add comment

You can also use ruby-debug_pry which integrates pry as a ruby-debug command, enabling you to easily switch back and forth between the two.

A new project called pry-nav is now the recommended way to do this.

share|improve this answer
I'll check that out as well; thanks. –  Dave Newton Oct 20 '11 at 0:36
add comment

If using Using MRI 1.9.2+ then there is a new project, pry-debugger, that is now the recommended replacement for pry-nav. It's by the same author as pry-nav and is faster.

share|improve this answer
add comment

Ctrl+D, you can jump to next break or exit

share|improve this answer
cool dadd-yo, i like the cut of your jib. –  banister Jul 13 '13 at 11:10
this worked for me. –  snowking16 May 9 at 21:30
add comment

Recommend to use pry-byebug if ruby version >2.0

share|improve this answer
add comment

Your Answer


