diff options
Diffstat (limited to 'bin/rbot')
-rwxr-xr-x | bin/rbot | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -35,11 +35,12 @@ $opts = Hash.new orig_opts = ARGV.dup opts = GetoptLong.new( + ["--background", "-b", GetoptLong::NO_ARGUMENT], ["--debug", "-d", GetoptLong::NO_ARGUMENT], ["--help", "-h", GetoptLong::NO_ARGUMENT], + ["--loglevel", "-l", GetoptLong::REQUIRED_ARGUMENT], ["--trace", "-t", GetoptLong::REQUIRED_ARGUMENT], - ["--version", "-v", GetoptLong::NO_ARGUMENT], - ["--background", "-b", GetoptLong::NO_ARGUMENT] + ["--version", "-v", GetoptLong::NO_ARGUMENT] ) $debug = false @@ -51,6 +52,8 @@ opts.each {|opt, arg| $opts[opt.sub(/^-+/, "")] = arg } +$cl_loglevel = $opts["loglevel"] + if ($opts["trace"]) set_trace_func proc { |event, file, line, id, binding, classname| if classname.to_s == $opts["trace"] |