[ANN] Ruby Debugging Article at IBM Developerworks

L

Levin Alexander

T24gOS82LzA1LCBtYXRoZXcgPG1ldGFAcG9ib3guY29tPiB3cm90ZToKCj4gVGhhdCBpcywgaWYg
SSBoYXZlIHRoZSBzb3VyY2UgZmlsZSBvcGVuIGluIG15IGVkaXRvciwgSSdkIGxpa2UgdG8gYmUK
PiBhYmxlIHRvIHdyaXRlIHNvbWV0aGluZyBsaWtlCj4gCj4gICAgIHRyaWdnZXJfZGVidWdnZXIg
aWYgJERFQlVHCgokIGdlbSBpbnN0YWxsIHJ1YnktYnJlYWtwb2ludAoKICByZXF1aXJlICdydWJ5
Z2VtcycKICByZXF1aXJlICdicmVha3BvaW50JwoKICBicmVha3BvaW50IGlmICRERUJVRwoKcHV0
cyB5b3UgaW50byBhbiBpbnRlcmFjdGl2ZSBpcmIgc2Vzc2lvbgoKLUxldmluCg==
 
C

Caleb Clausen

Levin said:
$ gem install ruby-breakpoint

require 'rubygems'
require 'breakpoint'

breakpoint if $DEBUG
=20
puts you into an interactive irb session

Or, to stop in the debugger, try this:

defined? DEBUGGER__ and Process.kill("INT",0)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,822
Latest member
israfaceZa

Latest Threads

Top