| 1 |
{# Signature state for a commit or a tag. Expects `sig` in scope. |
| 2 |
|
| 3 |
Nothing renders for an unsigned object. Every forge that badges "unsigned" |
| 4 |
is training people to ignore the badge, and the overwhelming majority of |
| 5 |
commits everywhere are unsigned. Only a signature that exists says anything. |
| 6 |
|
| 7 |
The verified case names the signer, which is the thing no forge without its |
| 8 |
own key store can do: the key that made the signature is the key that |
| 9 |
authenticates their pushes. #} |
| 10 |
{% match sig %} |
| 11 |
{% when git::signing::SignatureStatus::Unsigned %} |
| 12 |
{% when git::signing::SignatureStatus::SignedBy { username, fingerprint } %} |
| 13 |
<span class="git-signature is-verified" title="{{ fingerprint }}"> |
| 14 |
Signed by <a href="/u/{{ username }}">{{ username }}</a> |
| 15 |
</span> |
| 16 |
{% when git::signing::SignatureStatus::ValidUnknownKey { fingerprint } %} |
| 17 |
<span class="git-signature" title="{{ fingerprint }}"> |
| 18 |
Signed, key not registered here |
| 19 |
</span> |
| 20 |
{% when git::signing::SignatureStatus::Invalid %} |
| 21 |
<span class="git-signature is-bad">Signature does not verify</span> |
| 22 |
{% when git::signing::SignatureStatus::Unverified { format } %} |
| 23 |
<span class="git-signature">Signed with {{ format }}, not checked</span> |
| 24 |
{% endmatch %} |
| 25 |
|