guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

05/05: installer: Use a different mount-point for each install attempt.


From: John Darrington
Subject: 05/05: installer: Use a different mount-point for each install attempt.
Date: Mon, 13 Feb 2017 16:00:56 -0500 (EST)

jmd pushed a commit to branch wip-installer
in repository guix.

commit 25c91adcd5df051be78ccbf16d906410fa61ecf9
Author: John Darrington <address@hidden>
Date:   Mon Feb 13 14:53:48 2017 +0100

    installer:  Use a different mount-point for each install attempt.
    
    * gnu/system/installer/install.scm (install-page-key-handler): When
    attempting to remount devices prior to installing, use a disctinct
    mount-point prefix for each attempt.
---
 gnu/system/installer/install.scm | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/gnu/system/installer/install.scm b/gnu/system/installer/install.scm
index 898f3aa..592e49e 100644
--- a/gnu/system/installer/install.scm
+++ b/gnu/system/installer/install.scm
@@ -102,12 +102,13 @@
       (force-reboot))
 
      ((buttons-key-matches-symbol? nav ch 'continue)
-      (let ((target "/target")
-            (window-port (make-window-port config-window)))
+      (let* ((attempt (page-datum page 'attempt))
+             (target (format #f "/target-~a" attempt))
+             (window-port (make-window-port config-window)))
         (catch #t
                (lambda ()
+                 (page-set-datum! page 'attempt (1+ attempt))
                  (and
-
                   (fold
                    (lambda (x prev)
                      (and prev
@@ -201,6 +202,7 @@
     (page-set-wwin! p pr)
     (page-set-datum! p 'navigation buttons)
     (page-set-datum! p 'config-window (inner config-window))
+    (page-set-datum! p 'attempt 0)
     (buttons-post buttons bwin)
     (refresh* (outer pr))
     (refresh* text-window)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]