summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--autobuild/results.php11
1 files changed, 9 insertions, 2 deletions
diff --git a/autobuild/results.php b/autobuild/results.php
index ad471cf..29f988b 100644
--- a/autobuild/results.php
+++ b/autobuild/results.php
@@ -31,8 +31,15 @@ while (false !== ($entry = readdir($handle))) {
closedir($handle);
sort($runs);
-# TODO: glob on arch and take most recent
-$latest = readlink("cauldron/x86_64/core/latest");
+$latestlinks = array_values(glob("cauldron/*/core/latest"));
+$latest = 0;
+foreach ($latestlinks as $link) {
+ $date = readlink($link);
+ if ($date > $latest) {
+ $latest = $date;
+ }
+}
+
$run = $_GET['run'];
if (!$run) {
$run = $latest;