mtrace 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/example.rb +1 -0
- data/lib/mtrace.rb +3 -1
- data/screenshot.png +0 -0
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.1
|
data/example.rb
CHANGED
data/lib/mtrace.rb
CHANGED
@@ -2,7 +2,9 @@ mtrace_indent = 0
|
|
2
2
|
set_trace_func lambda {|event, file, line, id, binding, klass|
|
3
3
|
case event
|
4
4
|
when 'call'
|
5
|
-
puts "\e[90m| " * mtrace_indent +
|
5
|
+
puts "\e[90m| " * mtrace_indent +
|
6
|
+
"\e[35m#{klass}\e[90m#\e[36m#{id} \e[90m#{file}:#{line}\e[0m" +
|
7
|
+
"#{' ' * ([10 - mtrace_indent, 1].max)}\e[90mtxmt://open/?url=file://#{ File.expand_path(file).sub(File.expand_path('~'), '~') }&line=#{ line }\e[0m"
|
6
8
|
mtrace_indent += 1
|
7
9
|
when 'return'
|
8
10
|
mtrace_indent -= 1
|
data/screenshot.png
CHANGED
Binary file
|