GNU bug report logs - #42634
[PATCH 0/3] Add image-type support.

Previous Next

Package: guix-patches;

Reported by: Mathieu Othacehe <m.othacehe <at> gmail.com>

Date: Fri, 31 Jul 2020 14:49:01 UTC

Severity: normal

Tags: patch

Done: Mathieu Othacehe <othacehe <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Mathieu Othacehe <m.othacehe <at> gmail.com>
To: 42634 <at> debbugs.gnu.org
Cc: Mathieu Othacehe <othacehe <at> gnu.org>
Subject: [bug#42634] [PATCH 1/3] image: Add image-type support.
Date: Fri, 31 Jul 2020 16:49:27 +0200
* gnu/image.scm (<image-type>): New record,
(image-type, image-type?, image-type-name,
image-type-constructor, os->image): new procedures.
---
 gnu/image.scm | 29 ++++++++++++++++++++++++++++-
 1 file changed, 28 insertions(+), 1 deletion(-)

diff --git a/gnu/image.scm b/gnu/image.scm
index dc66f2c533..6f8f4828ac 100644
--- a/gnu/image.scm
+++ b/gnu/image.scm
@@ -39,7 +39,14 @@
             image-partitions
             image-compression?
             image-volatile-root?
-            image-substitutable?))
+            image-substitutable?
+
+            image-type
+            image-type?
+            image-type-name
+            image-type-constructor
+
+            os->image))
 
 
 ;;;
@@ -84,3 +91,23 @@
                       (default #t))
   (substitutable?     image-substitutable? ;boolean
                       (default #t)))
+
+
+;;;
+;;; Image type.
+;;;
+
+(define-record-type* <image-type>
+  image-type make-image-type
+  image-type?
+  (name           image-type-name) ;string
+  (constructor    image-type-constructor)) ;<operating-system> -> <image>
+
+
+;;;
+;;; Image creation.
+;;;
+
+(define* (os->image os #:key type)
+  (let ((constructor (image-type-constructor type)))
+    (constructor os)))
-- 
2.26.2





This bug report was last modified 4 years and 240 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.