{# vim ft=django #} {% import "scmutils.html" as utils with context %}
{{ utils.commit_event(repo, commit, full=True) }}
{#
          #}{{stats.count_files}} files changed, {{stats.count_insertions}} insertions(+), {{stats.count_deletions}} deletions(-)

{#       #}{% for change in changes -%}
             {{change.status_char}}
             {%- if change.old_file.path != change.new_file.path -%}
               {% if change.old_file.path %} {{change.old_file.path}}{% endif %} =>
             {%- endif %} {{change.new_file.path}}
{#       #}{% endfor -%}
          
{% for change in changes -%}
{{change.status_char}}
          {%- if change.old_file.path != change.new_file.path -%}
          {% if change.old_file.path %} {{change.old_file.path}}{% endif %} =>
          {%- endif %} {{change.new_file.path}}{#
        #}{#
          #} +{{change.count_insertions}}{#
          #} -{{change.count_deletions}}{#
        #}{#
      #}
          {%- for hunk in change.hunks %}
{#      #}{%- set hunk_index = loop.index -%}
          @@ {{hunk.old_start}},{{hunk.old_lines}} {{hunk.new_start}},{{hunk.new_lines}} @@{#
        #}
{#      #}{% for line in hunk.lines -%}
            
                {%- if line.inserted -%}
                  +
                {%- elif line.deleted -%}
                  -
                {%- else %} {% endif -%}
              
              {%- if loop.first and hunk.old_start != 0 -%}
                {{line.content.lstrip()}}
              {%- else -%}
                {{line.content}}
              {%- endif -%}
            
          {%- endfor %}
          {% endfor -%}
          
{% endfor -%}