woodpecker-email/templates/build_status.html.twig
Simon Vieille 65f4049c28
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
refactor all by using PHP instead of Golang
2024-01-15 12:38:30 +01:00

94 lines
4.5 KiB
Twig

{% extends '_base.html.twig' %}
{% block body %}
<table class="body-wrap">
<tr>
<td></td>
<td class="container" width="600">
<div class="content">
<table class="main" width="100%" cellpadding="0" cellspacing="0">
<tr>
{% if build.pipeline.status == 'success' %}
<td class="alert alert-good">
<a href="{{ build.pipeline.url }}">
Successful pipeline #{{ build.pipeline.number }}
</a>
</td>
{% else %}
<td class="alert alert-bad">
<a href="{{ build.pipeline.url }}">
Failed pipeline #{{ build.pipeline.number }}
</a>
</td>
{% endif %}
</tr>
<tr>
<td class="content-wrap">
{% if body is defined %}
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td>{{ include(template_from_string(body), build) }}</td>
</tr>
</table>
{% else %}
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td>
Repo:
</td>
<td>
{{ build.repo.full_name }}
</td>
</tr>
<tr>
<td>
Author:
</td>
<td>
{{ build.commit.author }} ({{ build.commit.author_email }})
</td>
</tr>
<tr>
<td>
Branch:
</td>
<td>
{{ build.commit.branch }}
</td>
</tr>
<tr>
<td>
Commit:
</td>
<td>
{{ build.commit.sha[0:8] }}
</td>
</tr>
<tr>
<td>
Started at:
</td>
<td>
{{ build.build.created_at|date('r') }}
</td>
</tr>
</table>
<hr>
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td>
{{ build.commit.message }}
</td>
</tr>
</table>
{% endif %}
</td>
</tr>
</table>
</div>
</td>
<td></td>
</tr>
</table>
{% endblock %}