1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// ==UserScript==
// @name       Link Rockbox build logs on round stats page
// @namespace  http://build.rockbox.org/
// @version    0.1
// @match      http://build.rockbox.org/data/*-clients.html
// @copyright  2013 by Michael Sparmann (TheSeven)
// ==/UserScript==

var title = document.getElementsByTagName("h1")[0];
var rev = title.firstChild.nodeValue.split(" ");
rev = rev[rev.length - 1];
var builds = title.parentNode.getElementsByTagName("span");
for (var i = builds.length; --i >= 0;)
{
    var old = builds[i];
    var build = document.createElement("a");
    build.href = "../shownewlog.cgi?rev=" + rev + ";type=" + old.title;
    old.parentNode.insertBefore(build, old);
    old.parentNode.removeChild(old);
    build.appendChild(old);
}