cbaines pushed a commit to branch master
in repository guix.

commit d262248c55e7674081a455d33a067c026fcc31cf
Author: Maxim Cournoyer <[email protected]>
AuthorDate: Sun Mar 23 22:14:59 2025 +0900

    gnu: localed: Remove trailing #t and re-indent.
    
    * gnu/packages/freedesktop.scm (localed) [source]: Remove trailing #t in
    snippet.
    [arguments] <#:phases>: Likewise.
    
    Change-Id: Icf651d806e43a8d8dc8996c612f028285086d6b8
---
 gnu/packages/freedesktop.scm | 119 ++++++++++++++++++++++---------------------
 1 file changed, 60 insertions(+), 59 deletions(-)

diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm
index 4baf535c17..2db7088cf9 100644
--- a/gnu/packages/freedesktop.scm
+++ b/gnu/packages/freedesktop.scm
@@ -1084,8 +1084,7 @@ This library provides just sd-bus (and the busctl 
utility).")
                   ;; 'localectl' would exit without doing anything.)
                   (substitute* "src/shared/bus-util.c"
                     (("sd_booted\\(\\)")
-                     "(1)"))
-                  #t))
+                     "(1)"))))
               (patches (search-patches "localed-xorg-keyboard.patch"))))
     (build-system meson-build-system)
     (arguments
@@ -1130,63 +1129,65 @@ This library provides just sd-bus (and the busctl 
utility).")
          ;; It doesn't make sense to test all of systemd.
          #:tests? #f
 
-         #:phases (modify-phases %standard-phases
-                    (add-after 'unpack 'set-xkeyboard-config-file-name
-                      (lambda* (#:key inputs #:allow-other-keys)
-                        ;; Set the file name to xkeyboard-config and kbd.
-                        ;; This is used by 'localectl list-x11-keymap-layouts'
-                        ;; and similar functions.
-                        (let ((xkb (assoc-ref inputs "xkeyboard-config"))
-                              (kbd (assoc-ref inputs "kbd")))
-                          (substitute* "src/locale/localectl.c"
-                            (("/usr/share/X11/xkb/rules")
-                             (string-append xkb "/share/X11/xkb/rules")))
-                          (substitute* "src/basic/def.h"
-                            (("/usr/share/keymaps")
-                             (string-append kbd "/share/keymaps")))
-                          #t)))
-                    (replace 'install
-                      (lambda* (#:key outputs #:allow-other-keys)
-                        ;; Install 'localed', the D-Bus and polkit files, and
-                        ;; 'localectl'.
-                        (let* ((out (assoc-ref outputs "out"))
-                               (libexec (string-append out "/libexec/localed"))
-                               (bin     (string-append out "/bin"))
-                               (lib     (string-append out "/lib"))
-                               (dbus    (string-append out
-                                                       
"/share/dbus-1/system-services"))
-                               (conf    (string-append out
-                                                       
"/etc/dbus-1/system.d/"))
-                               (polkit  (string-append out
-                                                       
"/share/polkit-1/actions"))
-                               (data    (string-append out "/share/systemd")))
-                          (define (source-file regexp)
-                            (car (find-files ".." regexp)))
-
-                          (mkdir-p libexec)
-                          (copy-file "systemd-localed"
-                                     (string-append libexec "/localed"))
-                          (install-file "localectl" bin)
-
-                          (let ((service-file (source-file
-                                               "\\.locale1\\.service$")))
-                            (substitute* service-file
-                              (("^Exec=.*$")
-                               (string-append "Exec=" libexec "/localed\n")))
-                            (install-file service-file dbus))
-                          (install-file (source-file "\\.locale1\\.policy$")
-                                        polkit)
-                          (install-file (source-file "\\.locale1\\.conf$")
-                                        conf)
-                          (for-each (lambda (file)
-                                      (install-file file lib))
-                                    (find-files "src/shared"
-                                                "libsystemd-shared.*\\.so"))
-
-                          (for-each (lambda (map)
-                                      (install-file map data))
-                                    (find-files ".." 
"^(kbd-model-map|language-fallback-map)$"))
-                          #t)))))))
+         #:phases
+         (modify-phases %standard-phases
+           (add-after 'unpack 'set-xkeyboard-config-file-name
+             (lambda* (#:key inputs #:allow-other-keys)
+               ;; Set the file name to xkeyboard-config and kbd.
+               ;; This is used by 'localectl list-x11-keymap-layouts'
+               ;; and similar functions.
+               (let ((xkb (assoc-ref inputs "xkeyboard-config"))
+                     (kbd (assoc-ref inputs "kbd")))
+                 (substitute* "src/locale/localectl.c"
+                   (("/usr/share/X11/xkb/rules")
+                    (string-append xkb "/share/X11/xkb/rules")))
+                 (substitute* "src/basic/def.h"
+                   (("/usr/share/keymaps")
+                    (string-append kbd "/share/keymaps"))))))
+           (replace 'install
+             (lambda* (#:key outputs #:allow-other-keys)
+               ;; Install 'localed', the D-Bus and polkit files, and
+               ;; 'localectl'.
+               (let* ((out (assoc-ref outputs "out"))
+                      (libexec (string-append out "/libexec/localed"))
+                      (bin     (string-append out "/bin"))
+                      (lib     (string-append out "/lib"))
+                      (dbus    (string-append out
+                                              "/share/dbus-1/system-services"))
+                      (conf    (string-append out
+                                              "/etc/dbus-1/system.d/"))
+                      (polkit  (string-append out
+                                              "/share/polkit-1/actions"))
+                      (data    (string-append out "/share/systemd")))
+                 (define (source-file regexp)
+                   (car (find-files ".." regexp)))
+
+                 (mkdir-p libexec)
+                 (copy-file "systemd-localed"
+                            (string-append libexec "/localed"))
+                 (install-file "localectl" bin)
+
+                 (let ((service-file (source-file
+                                      "\\.locale1\\.service$")))
+                   (substitute* service-file
+                     (("^Exec=.*$")
+                      (string-append "Exec=" libexec "/localed\n")))
+                   (install-file service-file dbus))
+                 (install-file (source-file "\\.locale1\\.policy$")
+                               polkit)
+                 (install-file (source-file "\\.locale1\\.conf$")
+                               conf)
+                 (for-each (lambda (file)
+                             (install-file file lib))
+                           (find-files "src/shared"
+                                       "libsystemd-shared.*\\.so"))
+
+                 (for-each
+                  (lambda (map)
+                    (install-file map data))
+                  (find-files
+                   ".."
+                   "^(kbd-model-map|language-fallback-map)$")))))))))
     (native-inputs `(,@(package-native-inputs elogind)
                      ("rsync" ,rsync)))
     (inputs `(("libmount" ,util-linux "lib")

Reply via email to