[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
13/26: installer: Remove unnecessary "begin".
From: |
John Darrington |
Subject: |
13/26: installer: Remove unnecessary "begin". |
Date: |
Sun, 22 Jan 2017 12:09:24 +0000 (UTC) |
jmd pushed a commit to branch wip-installer
in repository guix.
commit c8314dc2162b0ac9b915a8d1fa3d1a8c7ea02d36
Author: John Darrington <address@hidden>
Date: Wed Jan 18 13:41:46 2017 +0100
installer: Remove unnecessary "begin".
* gnu/system/installer/wireless.scm (get-wifi): Remove superfluous "begin".
---
gnu/system/installer/wireless.scm | 86 ++++++++++++++++++-------------------
1 file changed, 43 insertions(+), 43 deletions(-)
diff --git a/gnu/system/installer/wireless.scm
b/gnu/system/installer/wireless.scm
index efaa87b..e26b257 100644
--- a/gnu/system/installer/wireless.scm
+++ b/gnu/system/installer/wireless.scm
@@ -181,49 +181,49 @@
s))
(define (get-wifi ifce)
- (begin (system* "ip" "link" "set" ifce "up")
- (fold
- (lambda (x prev)
- (let ((mtch (string-match "Cell [0-9][0-9] - " x)))
- (cond (mtch
- (cons
- (list
- `(address . ,
- (drop-prefix "Address: "
- (string-drop x (string-length
(match:substring mtch))))))
- prev))
-
- ((string-prefix? "Encryption key:" x)
- (cons
- (append (car prev)
- (list `(encryption .
- ,(string-suffix? "on" x))))
- (cdr prev)))
-
- ((string-prefix? "Quality=" x)
- (let ((lvl (string-match "level=(-?[0-9][0-9]*) dBm" x)))
- (if lvl
- (cons
- (append (car prev)
- (list
- `(signal . ,(string->number
(match:substring lvl 1))))
- )
- (cdr prev))
- prev)))
-
- ((string-prefix? "ESSID:" x)
- (cons
- (append (car prev)
- (list
- `(essid . ,(drop-prefix "ESSID:"
- (drop-quotes
- x))))
- )
- (cdr prev)))
-
- (else
- prev))))
- '() (scan-wifi ifce))))
+ (system* "ip" "link" "set" ifce "up")
+ (fold
+ (lambda (x prev)
+ (let ((mtch (string-match "Cell [0-9][0-9] - " x)))
+ (cond (mtch
+ (cons
+ (list
+ `(address . ,
+ (drop-prefix "Address: "
+ (string-drop x (string-length
(match:substring mtch))))))
+ prev))
+
+ ((string-prefix? "Encryption key:" x)
+ (cons
+ (append (car prev)
+ (list `(encryption .
+ ,(string-suffix? "on" x))))
+ (cdr prev)))
+
+ ((string-prefix? "Quality=" x)
+ (let ((lvl (string-match "level=(-?[0-9][0-9]*) dBm" x)))
+ (if lvl
+ (cons
+ (append (car prev)
+ (list
+ `(signal . ,(string->number (match:substring lvl
1))))
+ )
+ (cdr prev))
+ prev)))
+
+ ((string-prefix? "ESSID:" x)
+ (cons
+ (append (car prev)
+ (list
+ `(essid . ,(drop-prefix "ESSID:"
+ (drop-quotes
+ x))))
+ )
+ (cdr prev)))
+
+ (else
+ prev))))
+ '() (scan-wifi ifce)))
- 21/26: installer: Do not assume the root file system is of type "ext4"., (continued)
- 21/26: installer: Do not assume the root file system is of type "ext4"., John Darrington, 2017/01/22
- 17/26: installer: Note which types of file system are supported., John Darrington, 2017/01/22
- 25/26: installer: Emphasise that writing filesystems destroys existing data., John Darrington, 2017/01/22
- 05/26: installer: Fix bug where the selected item of main page was not indicated., John Darrington, 2017/01/22
- 08/26: gurses: form: Use match instead of car, cdr etc., John Darrington, 2017/01/22
- 03/26: installer: Do not allow the creation of invalid file-system specificaitons., John Darrington, 2017/01/22
- 15/26: gurses: Allow menu update to work for panel windows., John Darrington, 2017/01/22
- 18/26: gurses: Populate the choices box in forms., John Darrington, 2017/01/22
- 06/26: installer: Add an explanatory text to the main page., John Darrington, 2017/01/22
- 22/26: installer: mount-points page: Enlarge the forms window., John Darrington, 2017/01/22
- 13/26: installer: Remove unnecessary "begin".,
John Darrington <=
- 24/26: installer: Remove redundant list of file system types., John Darrington, 2017/01/22
- 20/26: gurses: Populate dropdown boxes in forms using a menu., John Darrington, 2017/01/22
- 12/26: installer: Fix bug in config generation., John Darrington, 2017/01/22
- 26/26: doc: Remove the text which mentions there is no graphical installer., John Darrington, 2017/01/22
- 19/26: installer: Add a popup window for forms which have multiple choice fields., John Darrington, 2017/01/22
- 16/26: gurses: Mini refactor., John Darrington, 2017/01/22
- 09/26: installer: Explicitly set the #:panel parameter for window creation procedures., John Darrington, 2017/01/22
- 11/26: installer: New procedure refresh*., John Darrington, 2017/01/22
- 23/26: gurses: Remove box from form popup window., John Darrington, 2017/01/22