require 'pluginscan/printer' module Pluginscan class SLOCCountPrinter < Printer def print(sloccount) print_headline print_results(sloccount) print_blank_line end private def print_headline @output.puts "Total sloccount (from David A. Wheeler's 'SLOCCount' tool):".color(:blue) end def print_results(sloccount) total = sloccount.total.to_s.color(:red) @output.puts " #{total} source lines of code" end end end