Class: DiffToHtml::SvnConverter

Inherits:
Converter show all
Defined in:
lib/diff_to_html/svn_converter.rb

Instance Attribute Summary

Attributes inherited from Converter

#file_prefix

Instance Method Summary collapse

Methods inherited from Converter

#composite_to_html, #diffs_to_html, #get_single_file_diff, #get_single_file_diff_body

Instance Method Details

#file_header_patternObject



4
5
6
# File 'lib/diff_to_html/svn_converter.rb', line 4

def file_header_pattern
  /^Index: .+/
end

#get_filename(header) ⇒ Object



8
9
10
11
12
# File 'lib/diff_to_html/svn_converter.rb', line 8

def get_filename(header)
  match = (header =~ /^Index: (.+)/) #if we use this pattern file_header_pattern files split doesn't work
  raise "header '#{header}' not matched!" if !match
  $1
end