bin/rdebug-ide in ruby-debug-ide-0.4.0 vs bin/rdebug-ide in ruby-debug-ide-0.4.1
- old
+ new
@@ -6,15 +6,16 @@
require 'ruby-debug'
$stdout.sync=true
options = OpenStruct.new(
+ 'frame_bind' => false,
'host' => nil,
+ 'load_mode' => false,
'port' => 1234,
- 'tracing' => false,
- 'frame_bind' => false,
- 'load_mode' => false
+ 'stop' => false,
+ 'tracing' => false
)
opts = OptionParser.new do |opts|
opts.banner = <<EOB
Using ruby-debug-base #{Debugger::VERSION}
@@ -22,10 +23,11 @@
EOB
opts.separator ""
opts.separator "Options:"
opts.on("-h", "--host HOST", "Host name used for remote debugging") {|options.host|}
opts.on("-p", "--port PORT", Integer, "Port used for remote debugging") {|options.port|}
+ opts.on('--stop', 'stop when the script is loaded') {options.stop = true}
opts.on("-x", "--trace", "turn on line tracing") {options.tracing = true}
opts.on("-l", "--load-mode", "load mode (experimental)") {options.load_mode = true}
opts.on("-d", "--debug", "Debug self - prints information for debugging ruby-debug itself") do
Debugger.cli_debug = true
end
@@ -73,8 +75,9 @@
# install interruption handler
trap('INT') { Debugger.interrupt_last }
# set options
Debugger.keep_frame_binding = options.frame_bind
+Debugger.tracing = options.tracing
-Debugger.main(options.host, options.port, options.load_mode)
+Debugger.debug_program(options)