summary refs log tree commit diff
diff options
context:
space:
mode:
authorMathieu Othacehe <othacehe@gnu.org>2021-04-28 11:52:31 +0200
committerMathieu Othacehe <othacehe@gnu.org>2021-04-28 11:53:32 +0200
commit3034f3d05bdd4e20fe07c329e41f831950d96f01 (patch)
treec53ba178fbacecd144b6804163af86aa0df2eaa2
parent996b5edf51c132764ca8122d401c5bb2b8d2e3c5 (diff)
downloadguix-3034f3d05bdd4e20fe07c329e41f831950d96f01.tar.gz
ci: Add arguments->systems procedure.
* gnu/ci.scm (arguments->systems): New procedure.
(cuirass-jobs): Use it.
-rw-r--r--gnu/ci.scm14
1 files changed, 10 insertions, 4 deletions
diff --git a/gnu/ci.scm b/gnu/ci.scm
index 9e4f0a8c82..58423b6911 100644
--- a/gnu/ci.scm
+++ b/gnu/ci.scm
@@ -72,6 +72,8 @@
             %core-packages
             %cross-targets
             channel-source->package
+
+            arguments->systems
             cuirass-jobs))
 
 ;;; Commentary:
@@ -443,6 +445,13 @@ valid."
                              load-manifest)
                     manifests))))
 
+(define (arguments->systems arguments)
+  "Return the systems list from ARGUMENTS."
+  (match (assoc-ref arguments 'systems)
+    (#f              %cuirass-supported-systems)
+    ((lst ...)       lst)
+    ((? string? str) (call-with-input-string str read))))
+
 
 ;;;
 ;;; Cuirass entry point.
@@ -454,10 +463,7 @@ valid."
     (assoc-ref arguments 'subset))
 
   (define systems
-    (match (assoc-ref arguments 'systems)
-      (#f              %cuirass-supported-systems)
-      ((lst ...)       lst)
-      ((? string? str) (call-with-input-string str read))))
+    (arguments->systems arguments))
 
   (define channels
     (let ((channels (assq-ref arguments 'channels)))