summaryrefslogtreecommitdiff
path: root/dedup/templates/binary.html
diff options
context:
space:
mode:
authorHelmut Grohne <helmut@subdivi.de>2013-07-27 09:32:03 +0200
committerHelmut Grohne <helmut@subdivi.de>2013-07-27 09:32:03 +0200
commit0c27c95a9c55b82b2c7e5e90b885c87578e895d0 (patch)
treef7b501e59dc15764a84ef9758f5b597e497719cf /dedup/templates/binary.html
parent03e7e27b440917081369e797e09de975912cb68c (diff)
downloaddebian-dedup-0c27c95a9c55b82b2c7e5e90b885c87578e895d0.tar.gz
move templates to dedup package
They cluttered webapp.py and now vim can give proper highlighting for the templates.
Diffstat (limited to 'dedup/templates/binary.html')
-rw-r--r--dedup/templates/binary.html31
1 files changed, 31 insertions, 0 deletions
diff --git a/dedup/templates/binary.html b/dedup/templates/binary.html
new file mode 100644
index 0000000..59c910c
--- /dev/null
+++ b/dedup/templates/binary.html
@@ -0,0 +1,31 @@
+{% extends "base.html" %}
+{% block title %}duplication of {{ package|e }}{% endblock %}
+{% block content %}<h1>{{ package|e }}</h1>
+<p>Version: {{ version|e }}</p>
+<p>Architecture: {{ architecture|e }}</p>
+<p>Number of files: {{ num_files }}</p>
+<p>Total size: {{ total_size|filesizeformat }}</p>
+{%- if shared -%}
+ {%- for function, sharing in shared.items() -%}
+ <h3>sharing with respect to {{ function|e }}</h3>
+ <table border='1'><tr><th>package</th><th>files shared</th><th>data shared</th></tr>
+ {%- for entry in sharing|sort(attribute="savable", reverse=true) -%}
+ <tr><td{% if not entry.package or entry.package in dependencies %} class="dependency"{% endif %}>
+ {%- if entry.package %}<a href="{{ entry.package|e }}"><span class="binary-package">{{ entry.package|e }}</span></a>{% else %}self{% endif -%}
+ <a href="../compare/{{ package|e }}/{{ entry.package|default(package, true)|e }}">compare</a></td>
+ <td>{{ entry.duplicate }} ({{ (100 * entry.duplicate / num_files)|int }}%)</td>
+ <td>{{ entry.savable|filesizeformat }} ({{ (100 * entry.savable / total_size)|int }}%)</td></tr>
+ {%- endfor -%}
+ </table>
+ {%- endfor -%}
+<p>Note: Packages with yellow background are required to be installed when this package is installed.</p>
+{%- endif -%}
+{%- if issues -%}
+ <h3>issues with particular files</h3>
+ <table border='1'><tr><th>filename</th><th>issue</th></tr>
+ {%- for filename, issue in issues|dictsort(true) -%}
+ <tr><td><span class="filename">{{ filename|e }}</span></td><td>{{ issue|e }}</td></tr>
+ {%- endfor -%}
+ </table>
+{%- endif -%}
+{% endblock %}