GNU bug report logs - #62103
[PATCH 0/2] redundant system degexp

Previous Next

Package: guix-patches;

Reported by: Bruno Victal <mirai <at> makinata.eu>

Date: Fri, 10 Mar 2023 20:18:02 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 62103 <at> debbugs.gnu.org (full text, mbox):

From: Bruno Victal <mirai <at> makinata.eu>
To: 62103 <at> debbugs.gnu.org
Cc: ludo <at> gnu.org, Bruno Victal <mirai <at> makinata.eu>
Subject: [PATCH 1/2] system: Simplify nsswitch binding.
Date: Fri, 10 Mar 2023 20:21:21 +0000
* gnu/system.scm (operating-system-etc-service): Simplify nsswitch binding.
---
 gnu/system.scm | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/gnu/system.scm b/gnu/system.scm
index bb26d7c9a5..2947d1321f 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -1001,10 +1001,9 @@ (define* (operating-system-etc-service os)
 
          (hurd       (operating-system-hurd os))
          (issue      (plain-file "issue" (operating-system-issue os)))
-         (nsswitch   (operating-system-name-service-switch os))
-         (nsswitch   (and nsswitch
-                          (plain-file "nsswitch.conf"
-                                      (name-service-switch->string nsswitch))))
+         (nsswitch   (and=> (operating-system-name-service-switch os)
+                            (compose (cut plain-file "nsswitch.conf" <>)
+                                     name-service-switch->string)))
          (sudoers    (operating-system-sudoers-file os))
 
         ;; Startup file for POSIX-compliant login shells, which set system-wide

base-commit: f7682c247504d252cf86b274ffe7b8f62670b497
-- 
2.39.1





This bug report was last modified 2 years and 73 days ago.

Previous Next


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