move templates to dedup package
[~helmut/debian-dedup.git] / dedup / templates / binary.html
1 {% extends "base.html" %}
2 {% block title %}duplication of {{ package|e }}{% endblock %}
3 {% block content %}<h1>{{ package|e }}</h1>
4 <p>Version: {{ version|e }}</p>
5 <p>Architecture: {{ architecture|e }}</p>
6 <p>Number of files: {{ num_files }}</p>
7 <p>Total size: {{ total_size|filesizeformat }}</p>
8 {%- if shared -%}
9     {%- for function, sharing in shared.items() -%}
10         <h3>sharing with respect to {{ function|e }}</h3>
11         <table border='1'><tr><th>package</th><th>files shared</th><th>data shared</th></tr>
12         {%- for entry in sharing|sort(attribute="savable", reverse=true) -%}
13             <tr><td{% if not entry.package or entry.package in dependencies %} class="dependency"{% endif %}>
14                 {%- if entry.package %}<a href="{{ entry.package|e }}"><span class="binary-package">{{ entry.package|e }}</span></a>{% else %}self{% endif -%}
15                 <a href="../compare/{{ package|e }}/{{ entry.package|default(package, true)|e }}">compare</a></td>
16             <td>{{ entry.duplicate }} ({{ (100 * entry.duplicate / num_files)|int }}%)</td>
17             <td>{{ entry.savable|filesizeformat }} ({{ (100 * entry.savable / total_size)|int }}%)</td></tr>
18         {%- endfor -%}
19         </table>
20     {%- endfor -%}
21 <p>Note: Packages with yellow background are required to be installed when this package is installed.</p>
22 {%- endif -%}
23 {%- if issues -%}
24     <h3>issues with particular files</h3>
25     <table border='1'><tr><th>filename</th><th>issue</th></tr>
26     {%- for filename, issue in issues|dictsort(true) -%}
27         <tr><td><span class="filename">{{ filename|e }}</span></td><td>{{ issue|e }}</td></tr>
28     {%- endfor -%}
29     </table>
30 {%- endif -%}
31 {% endblock %}