OXYGENHUB
# b6dfcb61cf5e oxygenhub / templates / change.html
4.6 KiB · HTML · last changed Long hashes and state addresses in change titles are shown by their ends 20 days ago source blame history raw
d23464c0 Andy McCall ↶ 1
{% extends "base.html" %}
2
{% import "repo_tabs.html" as m %}
3
{% block title %}{{ c.view.title }} · {{ c.view.short }} · {{ repo.owner }}/{{ repo.name }}{% endblock %}
4
{% block bodyattrs %} data-repo="{{ repo.url }}"{% endblock %}
5
{% block tabs %}{% call m::tabs(repo, "changes") %}{% endblock %}
6
{% block mainclass %} class="wide"{% endblock %}
7
{% block content %}
8
<article class="change">
62cdf34d Andy McCall ↶ 9
  <div class="head"><h1>{{ c.view.title|addresses }} <small class="px">{{ c.view.short }}</small>{% if c.view.resolution %} <span class="tag" title="Resolves conflicts; depends on every change that wrote a side">resolution</span>{% endif %}</h1></div>
d23464c0 Andy McCall ↶ 10
  {{ body_html|safe }}
11
  <dl class="facts">
8933faff Andy McCall ↶ 12
    <dt>Author</dt><dd>{% if let Some(a) = c.view.author.account %}<a href="/{{ a }}">{{ c.view.author.name }}</a> <span class="tag">@{{ a }}</span>{% else %}{{ c.view.author.name }}{% endif %}{% if !c.view.author.email.is_empty() %} <span class="mute">&lt;{{ c.view.author.email }}&gt;</span>{% endif %}{% if !c.view.author.key.is_empty() && c.view.author.account.is_none() %} <span class="tag" title="The key that signed this change is not linked to any account.">key not linked</span>{% if shell.user.is_some() %} <a class="small" href="/settings/keys">link your key</a>{% endif %}{% endif %}</dd>{% if let Some(v) = c.view.via %}
206c1fc1 Andy McCall ↶ 13
    <dt>via</dt><dd><span class="mute" aria-hidden="true">↳</span> <span class="tag{% if v.revoked %} bad{% endif %}" title="{{ v.title() }}">agent</span> <img class="avatar xs" src="/avatar/agent/{{ v.name }}" alt="" width="16" height="16"> {{ v.name }}{% if !v.email.is_empty() %} <span class="mute">&lt;{{ v.email }}&gt;</span>{% endif %} <span class="mute small">· {{ v.delegation() }} · key {{ v.short }}</span></dd>{% endif %}
d23464c0 Andy McCall ↶ 14
    <dt>When</dt><dd><time title="{{ c.view.when_ms|when }}">{{ c.view.when_ms|ago }}</time> · {{ c.view.when_ms|when }}</dd>
15
    <dt>Signature</dt><dd>{% call m::sig(c.view.signature) %} {{ c.view.signature.title() }}</dd>
16
    <dt>Hash</dt><dd><code class="full">{{ c.view.hash }}</code> <button class="small" data-copy="{{ c.view.hash }}">copy</button></dd>
17
    <dt>Depends on</dt><dd>{% if c.deps.is_empty() %}<span class="mute">nothing: a root change</span>{% else %}{% for d in c.deps %}<a class="chip" href="{{ repo.url }}/change/{{ d.hash }}" title="{{ d.title }}">{{ d.short }}</a> {% endfor %}{% endif %}</dd>
18
    <dt>Depended on by</dt><dd>{% if c.dependents.is_empty() %}<span class="mute">nothing yet</span>{% else %}{% for d in c.dependents %}<a class="chip" href="{{ repo.url }}/change/{{ d.hash }}" title="{{ d.title }}">{{ d.short }}</a> {% endfor %}{% endif %}</dd>
19
    <dt>In bookmarks</dt><dd>{% for b in c.in_bookmarks %}<a class="lbl lbl-bm" href="{{ repo.url }}/tree/{{ b }}">{{ b }}</a> {% endfor %}{% if c.in_bookmarks.is_empty() %}<span class="mute">none</span>{% endif %}</dd>
20
    {% if !c.in_tags.is_empty() %}<dt>In tags</dt><dd>{% for t in c.in_tags %}<a class="lbl lbl-tag" href="{{ repo.url }}/tree/{{ t }}">{{ t }}</a> {% endfor %}</dd>{% endif %}
cc19697f Andy McCall ↶ 21
    {% if !receipts.is_empty() %}<dt>Receipts</dt><dd class="receipts">{% for r in receipts %}<div><span class="flow-glyph st-{% if r.passed() %}passed{% else %}failed{% endif %}">{% if r.passed() %}✔{% else %}✘{% endif %}</span> {% if r.run.is_empty() %}<strong>{{ r.job }}</strong>{% else %}<a href="{{ r.run }}"><strong>{{ r.job }}</strong></a>{% endif %} <span class="small mute">{% if r.passed() %}passed{% else %}exit {{ r.exit_code }}{% endif %} in {{ r.duration }} · signed by {{ r.runner }} · <time title="{{ r.made_ms|when }}">{{ r.made_ms|ago }}</time></span>{% if !r.problem.is_empty() %} <span class="small warn">{{ r.problem }}</span>{% endif %} <a class="small" href="{{ repo.url }}/receipts/{{ r.attest }}" title="The signed receipt, for oxy receipt verify">download</a></div>{% endfor %}</dd>{% endif %}
d23464c0 Andy McCall ↶ 22
    <dt>Edits</dt><dd>{{ c.atoms|plural("atom", "atoms") }}, {{ c.tree_ops|plural("tree operation", "tree operations") }}, {{ files.len()|plural("file", "files") }}</dd>
23
  </dl>
4f692533 Andy McCall ↶ 24
  <p class="small"><a href="{{ repo.url }}/tree/{{ c.view.hash }}">Browse the tree at this change</a>{% if can_run %} · <form class="inline" method="post" action="{{ repo.url }}/flow/start"><input type="hidden" name="_csrf" value="{{ shell.csrf }}"><input type="hidden" name="change" value="{{ c.view.hash }}"><button type="submit" class="small" title="Run the pipeline on the state whose only head is this change">Run pipeline on this change</button></form>{% endif %}</p>
d23464c0 Andy McCall ↶ 25
  <nav class="files small">{% for f in files %}<a href="#{{ f.anchor }}">{{ f.path }}</a>{% endfor %}</nav>
9df855f2 Andy McCall ↶ 26
  {% call m::diff(files, ignore_ws, "") %}
d23464c0 Andy McCall ↶ 27
</article>
28
{% endblock %}