lib/hagma/extractor.rb
# Format the extracted lines by default. You can customize the fomatter in initialization.
Format the extracted lines by default. You can customize the fomatter in initialization.
Format the extracted lines by default . You can customize the fomatter in initialization .
def format(lines, cur_no)
        lastno = lines.keys.max
        lines.map do |num, line|
          sign = num + 1 == cur_no ? '=> ' : ' ' * 3
          super('%s%*d: %s', sign, lastno.to_s.size, num + 1, line)
        end.join("\n")
      end
def format ( lines , cur_no ) lastno = lines . keys . max lines . map do | num , line | sign = num + 1 == cur_no ? '=> ' : ' ' * 3 super ( '%s%*d: %s' , sign , lastno . to_s . size , num + 1 , line ) end . join ( "\n" ) end
Format the extracted lines by default.
Format the extracted lines by default .
lines
<not_specific>
cur_no
<not_specific>