Sort and count refs

This commit is contained in:
Joscha 2023-08-06 13:46:10 +02:00
parent 72f762464d
commit 520ee0f7da
3 changed files with 22 additions and 13 deletions

View file

@ -5,24 +5,20 @@
{% block body %}
<h2>Refs</h2>
<details>
<summary>Tracked</summary>
<summary>Tracked ({{ tracked_refs.len() }})</summary>
<dl>
{% for ref in refs %}
{% if ref.tracked %}
{% for ref in tracked_refs %}
<dt>{{ ref.name }}</dt>
<dd><a href="{{ base }}/commit/{{ ref.hash }}">{{ ref.short }}</a></dd>
{% endif %}
{% endfor %}
</dl>
</details>
<details>
<summary>Untracked</summary>
<summary>Untracked ({{ untracked_refs.len() }})</summary>
<dl>
{% for ref in refs %}
{% if !ref.tracked %}
{% for ref in untracked_refs %}
<dt>{{ ref.name }}</dt>
<dd><a href="{{ base }}/commit/{{ ref.hash }}">{{ ref.short }}</a></dd>
{% endif %}
{% endfor %}
</dl>
</details>