From: Mark Wielaard <mark@klomp.org>
To: buildbot@sourceware.org
Cc: Mark Wielaard <mark@klomp.org>
Subject: [PATCH] htdocs/INDEX.sh: Select only active builders
Date: Sat, 20 Jan 2024 04:36:24 +0100 [thread overview]
Message-ID: <20240120033624.411664-1-mark@klomp.org> (raw)
buildbot remembers all builders, but will list inactive builders
with an empty masterids array. So use jq to select only those
builders that have a non-empty masterids field.
---
htdocs/INDEX.sh | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/htdocs/INDEX.sh b/htdocs/INDEX.sh
index 72e94c3..b185ea7 100755
--- a/htdocs/INDEX.sh
+++ b/htdocs/INDEX.sh
@@ -8,8 +8,9 @@ cat index.html.pre
echo '<table>'
lastproject=
-curl -s https://builder.sourceware.org/buildbot/api/v2/builders | jq -r '.builders[].name' |
- sort |
+curl -s https://builder.sourceware.org/buildbot/api/v2/builders \
+ | jq -r '[ .builders[] | { "name": .name, "ids": .masterids | length } ]
+ | map(select(.ids > 0)) | [.[].name] | sort | .[]' |
egrep -v '__Janitor|sourceware' |
while read projbuilder
do
--
2.39.3
reply other threads:[~2024-01-20 3:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240120033624.411664-1-mark@klomp.org \
--to=mark@klomp.org \
--cc=buildbot@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).