Fix the JSON output for the derivation history page
This commit is contained in:
parent
32e1fee7ea
commit
af1324855e
2 changed files with 17 additions and 17 deletions
|
|
@ -124,22 +124,22 @@
|
|||
mime-types)
|
||||
((application/json)
|
||||
(render-json
|
||||
`((versions . ,(list->vector
|
||||
(map (match-lambda
|
||||
((package-version derivation-file-name
|
||||
first-guix-revision-commit
|
||||
first-datetime
|
||||
last-guix-revision-commit
|
||||
last-datetime)
|
||||
`((version . ,package-version)
|
||||
(derivation . ,derivation-file-name)
|
||||
(first_revision
|
||||
. ((commit . ,first-guix-revision-commit)
|
||||
(datetime . ,first-datetime)))
|
||||
(last_revision
|
||||
. ((commit . ,last-guix-revision-commit)
|
||||
(datetime . ,last-datetime))))))
|
||||
package-versions))))))
|
||||
`((derivations . ,(list->vector
|
||||
(map (match-lambda
|
||||
((package-version derivation-file-name
|
||||
first-guix-revision-commit
|
||||
first-datetime
|
||||
last-guix-revision-commit
|
||||
last-datetime)
|
||||
`((version . ,package-version)
|
||||
(derivation . ,derivation-file-name)
|
||||
(first_revision
|
||||
. ((commit . ,first-guix-revision-commit)
|
||||
(datetime . ,first-datetime)))
|
||||
(last_revision
|
||||
. ((commit . ,last-guix-revision-commit)
|
||||
(datetime . ,last-datetime))))))
|
||||
package-derivations))))))
|
||||
(else
|
||||
(render-html
|
||||
#:sxml (view-branch-package-derivations
|
||||
|
|
|
|||
|
|
@ -318,7 +318,7 @@
|
|||
"/repository/" git-repository-id
|
||||
"/branch/" branch-name
|
||||
"/package/" package-name
|
||||
".json")))
|
||||
"/derivation-history.json")))
|
||||
"View JSON")
|
||||
(h1 (@ (style "white-space: nowrap;"))
|
||||
(samp ,package-name))))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue