lib/earthquake/ext.rb in earthquake-0.6.10 vs lib/earthquake/ext.rb in earthquake-0.6.11

- old
+ new

@@ -43,10 +43,10 @@ "\e[#{codes.join(';')}m#{self}\e[0m" end def coloring(pattern, color = nil, &block) self.gsub(pattern) do |i| - applied_colors = self[0...$~.begin(0)].scan(/\e\[[\d;]+m/) + applied_colors = $`.scan(/\e\[[\d;]+m/) c = color || block.call(i) "#{i.c(c)}#{applied_colors.join}" end end \ No newline at end of file