53 lines
1.5 KiB
Plaintext
53 lines
1.5 KiB
Plaintext
@page
|
|
@using System.Web
|
|
@model IndexModel
|
|
@{
|
|
ViewData["Title"] = "Builds";
|
|
}
|
|
|
|
<div class="text-center">
|
|
<h1 class="display-4">Builds</h1>
|
|
</div>
|
|
|
|
<table class="table">
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">Package</th>
|
|
<th scope="col">Version</th>
|
|
<th scope="col">Build status</th>
|
|
<th scope="col">Log</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach (var p in Program.Repo._repo.Packages.OrderBy(p => p.Name))
|
|
{
|
|
<tr>
|
|
<th scope="row">@p.Name</th>
|
|
@if (p.CurrentVersion == p.RepoVersion)
|
|
{
|
|
<td><span class="badge badge-success">up-to-date</span> <span class="badge badge-info">@p.RepoVersion</span></td>
|
|
}
|
|
else
|
|
{
|
|
<td><span class="badge badge-warning">pending update</span> <span class="badge badge-danger">@p.RepoVersion</span> <span class="badge badge-secondary">@p.CurrentVersion</span></td>
|
|
}
|
|
@if (p.LastBuildSucceeded)
|
|
{
|
|
<td><span class="badge badge-success">Build passing</span></td>
|
|
}
|
|
else
|
|
{
|
|
<td><span class="badge badge-danger">Build failing</span></td>
|
|
}
|
|
@if (System.IO.File.Exists(System.IO.Path.Combine(Program.Repo._logpath, $"{p.Name}.log")))
|
|
{
|
|
<td><a role="button" class="btn btn-sm btn-info" target="_blank" href="/Log?package=@HttpUtility.UrlEncode(p.Name)">View Build log</a></td>
|
|
}
|
|
else
|
|
{
|
|
<td>no logfile found</td>
|
|
}
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table> |