Add a few new pages

For showing more information about builds, revisions and derivations.
This commit is contained in:
Christopher Baines 2019-03-06 22:59:27 +00:00
parent e656b0967b
commit b0eaf9cf7a
Signed by: cbaines
GPG key ID: 5E28A33B0B84F577
3 changed files with 131 additions and 0 deletions

View file

@ -28,6 +28,8 @@
#:use-module (squee)
#:use-module (guix-data-service comparison)
#:use-module (guix-data-service model guix-revision)
#:use-module (guix-data-service model package)
#:use-module (guix-data-service model build)
#:use-module (guix-data-service jobs load-new-guix-revision)
#:use-module (guix-data-service web render)
#:use-module (guix-data-service web util)
@ -204,6 +206,19 @@
(apply render-html (index
(most-recent-n-guix-revisions conn 10)
(most-recent-n-load-new-guix-revision-jobs conn 1000))))
((GET "builds")
(apply render-html
(view-builds (select-build-stats conn)
(select-builds-with-context conn))))
((GET "revision" commit-hash)
(apply render-html
(view-revision commit-hash
(select-packages-in-revision conn
commit-hash))))
((GET "derivation" derivation-file-name ...)
(apply render-html
(view-derivation (string-append
"/" (string-join derivation-file-name "/")))))
((GET "compare")
(with-base-and-target-commits
request conn