Add a basic page for derivation source files
Just so that the links work.
This commit is contained in:
parent
759ced5c9d
commit
7c611402a0
2 changed files with 25 additions and 5 deletions
|
|
@ -147,12 +147,18 @@
|
||||||
(define (render-store-item conn filename)
|
(define (render-store-item conn filename)
|
||||||
(let ((derivation (select-derivation-by-output-filename conn filename)))
|
(let ((derivation (select-derivation-by-output-filename conn filename)))
|
||||||
(match derivation
|
(match derivation
|
||||||
|
(()
|
||||||
|
(match (select-derivation-source-file-by-store-path conn filename)
|
||||||
(()
|
(()
|
||||||
(render-html
|
(render-html
|
||||||
#:sxml (general-not-found
|
#:sxml (general-not-found
|
||||||
"Store item not found"
|
"Store item not found"
|
||||||
"No derivation found producing this output")
|
"No derivation found producing this output")
|
||||||
#:code 404))
|
#:code 404))
|
||||||
|
((id)
|
||||||
|
(render-html
|
||||||
|
#:sxml (view-derivation-source-file filename)
|
||||||
|
#:extra-headers http-headers-for-unchanging-content))))
|
||||||
(derivations
|
(derivations
|
||||||
(render-html
|
(render-html
|
||||||
#:sxml (view-store-item filename
|
#:sxml (view-store-item filename
|
||||||
|
|
|
||||||
|
|
@ -47,6 +47,7 @@
|
||||||
view-derivation
|
view-derivation
|
||||||
view-formatted-derivation
|
view-formatted-derivation
|
||||||
view-store-item
|
view-store-item
|
||||||
|
view-derivation-source-file
|
||||||
error-page))
|
error-page))
|
||||||
|
|
||||||
(define* (header)
|
(define* (header)
|
||||||
|
|
@ -516,6 +517,19 @@
|
||||||
derivations
|
derivations
|
||||||
derivations-using-store-item-list)))))
|
derivations-using-store-item-list)))))
|
||||||
|
|
||||||
|
(define (view-derivation-source-file filename)
|
||||||
|
(layout
|
||||||
|
#:body
|
||||||
|
`(,(header)
|
||||||
|
(div
|
||||||
|
(@ (class "container"))
|
||||||
|
(div
|
||||||
|
(@ (class "row"))
|
||||||
|
(div
|
||||||
|
(@ (class "col-sm-12"))
|
||||||
|
,(display-store-item-title filename)
|
||||||
|
"Derivation source file."))))))
|
||||||
|
|
||||||
(define (view-derivation derivation derivation-inputs derivation-outputs
|
(define (view-derivation derivation derivation-inputs derivation-outputs
|
||||||
builds)
|
builds)
|
||||||
(layout
|
(layout
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue