aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2019-10-14 18:38:11 +0100
committerChristopher Baines <mail@cbaines.net>2019-10-14 18:38:11 +0100
commit94256c4fa15b42139b51bbd60c051b0c9e0cbc43 (patch)
tree910c69fd508070db3eba744ae61ef071279504f6
parent86db73c05abed4feb830cb079c9d81ffd26eb949 (diff)
downloaddata-service-94256c4fa15b42139b51bbd60c051b0c9e0cbc43.tar
data-service-94256c4fa15b42139b51bbd60c051b0c9e0cbc43.tar.gz
Move the unknown-revision function to the correct module
-rw-r--r--guix-data-service/web/revision/html.scm44
-rw-r--r--guix-data-service/web/view/html.scm42
2 files changed, 43 insertions, 43 deletions
diff --git a/guix-data-service/web/revision/html.scm b/guix-data-service/web/revision/html.scm
index 1f3189a..f9f4500 100644
--- a/guix-data-service/web/revision/html.scm
+++ b/guix-data-service/web/revision/html.scm
@@ -27,7 +27,8 @@
view-revision-package-and-version
view-revision
view-revision-packages
- view-revision-lint-warnings))
+ view-revision-lint-warnings
+ unknown-revision))
(define* (view-revision-package revision-commit-hash
name
@@ -702,3 +703,44 @@
'())))
'()))))
lint-warnings))))))))))
+
+(define (unknown-revision commit-hash job git-repositories-and-branches
+ jobs-and-events)
+ (layout
+ #:body
+ `(,(header)
+ (div
+ (@ (class "container"))
+ ,@(match job
+ (()
+ `((h1 "Unknown revision")
+ (p "No known revision with commit "
+ (strong (samp ,commit-hash)))))
+ ((jobs ...)
+ `((div
+ (@ (class "row"))
+ (div
+ (@ (class "col-md-12"))
+ (h1 (@ (style "white-space: nowrap;"))
+ "Revision " (samp ,commit-hash))))
+ (div
+ (@ (class "row"))
+ (div
+ (@ (class "col-md-6"))
+ (h2 "Packages")
+ (strong (@ (class "text-center")
+ (style "font-size: 2em; display: block;"))
+ "Unknown")
+
+ ,@(if (null? git-repositories-and-branches)
+ '()
+ (view-revision/git-repositories
+ git-repositories-and-branches
+ commit-hash))
+ ,@(view-revision/jobs-and-events jobs-and-events))
+ (div
+ (@ (class "col-md-6"))
+ (h3 "Derivations")
+ (strong (@ (class "text-center")
+ (style "font-size: 2em; display: block;"))
+ "Unknown"))))))))))
diff --git a/guix-data-service/web/view/html.scm b/guix-data-service/web/view/html.scm
index 3102106..0972063 100644
--- a/guix-data-service/web/view/html.scm
+++ b/guix-data-service/web/view/html.scm
@@ -40,7 +40,6 @@
index
readme
general-not-found
- unknown-revision
view-statistics
view-builds
view-derivation
@@ -1195,47 +1194,6 @@
(h1 ,header-text)
(p ,body)))))
-(define (unknown-revision commit-hash job git-repositories-and-branches
- jobs-and-events)
- (layout
- #:body
- `(,(header)
- (div
- (@ (class "container"))
- ,@(match job
- (()
- `((h1 "Unknown revision")
- (p "No known revision with commit "
- (strong (samp ,commit-hash)))))
- ((jobs ...)
- `((div
- (@ (class "row"))
- (div
- (@ (class "col-md-12"))
- (h1 (@ (style "white-space: nowrap;"))
- "Revision " (samp ,commit-hash))))
- (div
- (@ (class "row"))
- (div
- (@ (class "col-md-6"))
- (h2 "Packages")
- (strong (@ (class "text-center")
- (style "font-size: 2em; display: block;"))
- "Unknown")
-
- ,@(if (null? git-repositories-and-branches)
- '()
- (view-revision/git-repositories
- git-repositories-and-branches
- commit-hash))
- ,@(view-revision/jobs-and-events jobs-and-events))
- (div
- (@ (class "col-md-6"))
- (h3 "Derivations")
- (strong (@ (class "text-center")
- (style "font-size: 2em; display: block;"))
- "Unknown"))))))))))
-
(define (compare-invalid-parameters query-parameters
base-job
target-job)