mirror of
https://github.com/golang/go
synced 2024-11-19 05:44:40 -07:00
2d83fa5bf1
This adds a "Git" dashboard at "/git/", which has its own namespace for datastore and memcache. Once we have pushed out the new git repositories we will spin up a commit watcher and builders that point to the Git dashboard. Once we are ready to switch the dashboard over to the new Git builders, the (*Dashboard).Context method will be changed to return "Git" as the default namespace. The old builders will be retired, and the new builders will be configured to report to "/" instead of "/git/". At that point all our old data will still be available in the default namespace, but hidden from view. LGTM=dsymonds, cmang R=bradfitz, cmang, dsymonds, adg CC=golang-codereviews https://golang.org/cl/183050043
211 lines
6.7 KiB
HTML
211 lines
6.7 KiB
HTML
<!DOCTYPE HTML>
|
|
<html>
|
|
<head>
|
|
<title>{{$.Dashboard.Name}} Build Dashboard</title>
|
|
<link rel="stylesheet" href="/static/style.css"/>
|
|
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script>
|
|
<script>
|
|
var showUnsupported = window.location.hash.substr(1) != "short";
|
|
function redraw() {
|
|
showUnsupported = !$("#showshort").prop('checked');
|
|
$('.unsupported')[showUnsupported?'show':'hide']();
|
|
window.location.hash = showUnsupported?'':'short';
|
|
}
|
|
$(document).ready(function() {
|
|
$("#showshort").attr('checked', !showUnsupported).change(redraw);
|
|
redraw();
|
|
})
|
|
</script>
|
|
</head>
|
|
|
|
<body>
|
|
<header id="topbar">
|
|
<h1>Go Dashboard</h1>
|
|
<nav>
|
|
<a href="{{$.Dashboard.Prefix}}/">Test</a>
|
|
<a href="{{$.Dashboard.Prefix}}/perf">Perf</a>
|
|
<a href="{{$.Dashboard.Prefix}}/perfgraph">Graphs</a>
|
|
</nav>
|
|
<div class="clear"></div>
|
|
</header>
|
|
|
|
<nav class="dashboards">
|
|
{{range buildDashboards}}
|
|
<a href="{{.Prefix}}/">{{.Name}}</a>
|
|
{{end}}
|
|
<label>
|
|
<input type=checkbox id="showshort">
|
|
show only <a href="http://golang.org/wiki/PortingPolicy">first-class ports</a>
|
|
</label>
|
|
</nav>
|
|
{{with $.Package.Name}}<h2>{{.}}</h2>{{end}}
|
|
|
|
<div class="page">
|
|
|
|
{{if $.Commits}}
|
|
|
|
<table class="build">
|
|
<colgroup class="col-hash" {{if $.Package.Path}}span="2"{{end}}></colgroup>
|
|
{{range $.Builders | builderSpans}}
|
|
<colgroup class="col-result{{if .Unsupported}} unsupported{{end}}" span="{{.N}}"></colgroup>
|
|
{{end}}
|
|
<colgroup class="col-user"></colgroup>
|
|
<colgroup class="col-time"></colgroup>
|
|
<colgroup class="col-desc"></colgroup>
|
|
<tr>
|
|
<!-- extra row to make alternating colors use dark for first result -->
|
|
</tr>
|
|
<tr>
|
|
{{if $.Package.Path}}
|
|
<th colspan="2">revision</th>
|
|
{{else}}
|
|
<th> </th>
|
|
{{end}}
|
|
{{range $.Builders | builderSpans}}
|
|
<th {{if .Unsupported}}class="unsupported"{{end}} colspan="{{.N}}">{{.OS}}</th>
|
|
{{end}}
|
|
<th></th>
|
|
<th></th>
|
|
<th></th>
|
|
</tr>
|
|
<tr>
|
|
{{if $.Package.Path}}
|
|
<th class="result arch">repo</th>
|
|
<th class="result arch">{{$.Dashboard.Name}}</th>
|
|
{{else}}
|
|
<th> </th>
|
|
{{end}}
|
|
{{range $.Builders}}
|
|
<th class="result arch{{if (unsupported .)}} unsupported{{end}}" title="{{.}}">{{builderSubheading .}}</th>
|
|
{{end}}
|
|
<th></th>
|
|
<th></th>
|
|
<th></th>
|
|
</tr>
|
|
{{range $c := $.Commits}}
|
|
{{range $i, $h := $c.ResultGoHashes}}
|
|
<tr class="commit">
|
|
{{if $i}}
|
|
<td> </td>
|
|
{{else}}
|
|
<td class="hash"><a href="{{repoURL $.Dashboard.Name $c.Hash $.Package.Path}}">{{shortHash $c.Hash}}</a></td>
|
|
{{end}}
|
|
{{if $h}}
|
|
<td class="hash"><a href="{{repoURL $.Dashboard.Name $h ""}}">{{shortHash $h}}</a></td>
|
|
{{end}}
|
|
{{range $.Builders}}
|
|
<td class="result{{if (unsupported .)}} unsupported{{end}}">
|
|
{{with $c.Result . $h}}
|
|
{{if .OK}}
|
|
<span class="ok">ok</span>
|
|
{{else}}
|
|
<a href="{{$.Dashboard.Prefix}}/log/{{.LogHash}}" class="fail">fail</a>
|
|
{{end}}
|
|
{{else}}
|
|
|
|
{{end}}
|
|
</td>
|
|
{{end}}
|
|
{{if $i}}
|
|
<td> </td>
|
|
<td> </td>
|
|
<td> </td>
|
|
{{else}}
|
|
<td class="user" title="{{$c.User}}">{{shortUser $c.User}}</td>
|
|
<td class="time">{{$c.Time.Format "Mon 02 Jan 15:04"}}</td>
|
|
<td class="desc" title="{{$c.Desc}}">{{shortDesc $c.Desc}}</td>
|
|
{{end}}
|
|
</tr>
|
|
{{end}}
|
|
{{end}}
|
|
</table>
|
|
|
|
{{with $.Pagination}}
|
|
<div class="paginate">
|
|
<nav>
|
|
<a {{if .HasPrev}}href="?{{with $.Package.Path}}repo={{.}}&{{end}}page={{.Prev}}{{with $.Branch}}&branch={{.}}{{end}}"{{else}}class="inactive"{{end}}>newer</a>
|
|
<a {{if .Next}}href="?{{with $.Package.Path}}repo={{.}}&{{end}}page={{.Next}}{{with $.Branch}}&branch={{.}}{{end}}"{{else}}class="inactive"{{end}}>older</a>
|
|
<a {{if .HasPrev}}href=".{{with $.Branch}}?branch={{.}}{{end}}"{{else}}class="inactive"{{end}}>latest</a>
|
|
</nav>
|
|
</div>
|
|
{{end}}
|
|
|
|
{{else}}
|
|
<p>No commits to display. Hm.</p>
|
|
{{end}}
|
|
|
|
{{with $.TipState}}
|
|
{{$goHash := .Tag.Hash}}
|
|
{{if .Packages}}
|
|
<h2>
|
|
Sub-repositories at tip
|
|
<small>(<a href="{{repoURL $.Dashboard.Name .Tag.Hash ""}}">{{shortHash .Tag.Hash}}</a>)</small>
|
|
</h2>
|
|
|
|
<table class="build">
|
|
<colgroup class="col-package"></colgroup>
|
|
<colgroup class="col-hash"></colgroup>
|
|
{{range $.Builders | builderSpans}}
|
|
<colgroup class="col-result{{if .Unsupported}} unsupported{{end}}" span="{{.N}}"></colgroup>
|
|
{{end}}
|
|
<colgroup class="col-user"></colgroup>
|
|
<colgroup class="col-time"></colgroup>
|
|
<colgroup class="col-desc"></colgroup>
|
|
<tr>
|
|
<!-- extra row to make alternating colors use dark for first result -->
|
|
</tr>
|
|
<tr>
|
|
<th></th>
|
|
<th></th>
|
|
{{range $.Builders | builderSpans}}
|
|
<th {{if .Unsupported}}class="unsupported"{{end}} colspan="{{.N}}">{{.OS}}</th>
|
|
{{end}}
|
|
<th></th>
|
|
<th></th>
|
|
<th></th>
|
|
</tr>
|
|
<tr>
|
|
<th></th>
|
|
<th></th>
|
|
{{range $.Builders}}
|
|
<th class="result arch{{if (unsupported .)}} unsupported{{end}}" title="{{.}}">{{builderSubheading .}}</th>
|
|
{{end}}
|
|
<th></th>
|
|
<th></th>
|
|
<th></th>
|
|
</tr>
|
|
{{range $pkg := .Packages}}
|
|
<tr class="commit">
|
|
<td><a title="{{.Package.Path}}" href="?repo={{.Package.Path}}">{{.Package.Name}}</a></td>
|
|
<td class="hash">
|
|
{{$h := $pkg.Commit.Hash}}
|
|
<a href="{{repoURL $.Dashboard.Name $h $pkg.Commit.PackagePath}}">{{shortHash $h}}</a>
|
|
</td>
|
|
{{range $.Builders}}
|
|
<td class="result{{if (unsupported .)}} unsupported{{end}}">
|
|
{{with $pkg.Commit.Result . $goHash}}
|
|
{{if .OK}}
|
|
<span class="ok">ok</span>
|
|
{{else}}
|
|
<a href="{{$.Dashboard.Prefix}}/log/{{.LogHash}}" class="fail">fail</a>
|
|
{{end}}
|
|
{{else}}
|
|
|
|
{{end}}
|
|
</td>
|
|
{{end}}
|
|
{{with $pkg.Commit}}
|
|
<td class="user" title="{{.User}}">{{shortUser .User}}</td>
|
|
<td class="time">{{.Time.Format "Mon 02 Jan 15:04"}}</td>
|
|
<td class="desc" title="{{.Desc}}">{{shortDesc .Desc}}</td>
|
|
{{end}}
|
|
</tr>
|
|
{{end}}
|
|
</table>
|
|
{{end}}
|
|
{{end}}
|
|
|
|
</div>
|
|
</body>
|
|
</html>
|