Hi Marius,

Marius Bakke <mba...@fastmail.com> writes:

> Timothy Sample <samp...@ngyro.com> writes:
>
>> [1] It’s not obvious, but if you edit the GDM configuration file
>> generation code in “gnu/services/xorg.scm”, you can enable debug output
>> for GDM.  The debug output is usually extremely helpful!
>
> Could that be exposed as a toggle in the service configuration?

Indeed!  It’s been on my list for ages.  Thanks for the nudge.  ;)

How about the attached patch?  I can confirm that it works, but would
like a second opinion on the name, since it is annoying to change later.

>From b3e577799c2dfabb2bed00b9f3715144155c2c43 Mon Sep 17 00:00:00 2001
From: Timothy Sample <samp...@ngyro.com>
Date: Wed, 23 Oct 2019 21:57:52 -0400
Subject: [PATCH] services: gdm: Add 'debug?' configuration field.

* gnu/services/xorg.scm (<gdm-configuration>)[debug?]: New field.
(gdm-configuration-file): Use it.
---
 gnu/services/xorg.scm | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/gnu/services/xorg.scm b/gnu/services/xorg.scm
index 1d55e388a1..9c84f7413f 100644
--- a/gnu/services/xorg.scm
+++ b/gnu/services/xorg.scm
@@ -835,6 +835,7 @@ the GNOME desktop environment.")
   (allow-empty-passwords? gdm-configuration-allow-empty-passwords? (default #t))
   (auto-login? gdm-configuration-auto-login? (default #f))
   (dbus-daemon gdm-configuration-dbus-daemon (default dbus-daemon-wrapper))
+  (debug? gdm-configuration-debug? (default #f))
   (default-user gdm-configuration-default-user (default #f))
   (gnome-shell-assets gdm-configuration-gnome-shell-assets
                       (default (list adwaita-icon-theme font-cantarell)))
@@ -866,7 +867,9 @@ the GNOME desktop environment.")
                    "WaylandEnable=false\n"
                    "\n"
                    "[debug]\n"
-                   "#Enable=true\n"
+                   "Enable=" (if (gdm-configuration-debug? config)
+                                 "true"
+                                 "false") "\n"
                    "\n"
                    "[security]\n"
                    "#DisallowTCP=true\n"
-- 
2.23.0

Thanks!


-- Tim

Reply via email to