services: Add %rosenthal-desktop-services-gdm.

* modules/rosenthal/services/desktop.scm (%rosenthal-desktop-services-gdm):
Extracted from...
(rosenthal-desktop-services-for-system): ...it.
Adjust accordingly.
This commit is contained in:
Hilton Chain 2026-02-04 22:54:15 +08:00
parent c2003fa60c
commit 4eba556e21
No known key found for this signature in database
GPG Key ID: ACC66D09CA528292

View File

@ -64,6 +64,7 @@
%rosenthal-set-keymap
%rosenthal-skeletons
%rosenthal-desktop-services-gdm
%rosenthal-desktop-services
%rosenthal-desktop-home-services))
@ -653,37 +654,8 @@ configuration {
;;; Service presets.
;;;
(define* (rosenthal-desktop-services-for-system
#:optional (system (or (%current-target-system)
(%current-system))))
(define %display-manager-service-type
(if (string-prefix? "x86_64" system)
gdm-service-type
sddm-service-type))
(define %term-font
(file-append (spec->pkg "font-terminus") "/share/consolefonts/ter-132n"))
(cons* (service greetd-service-type
(greetd-configuration
(greeter-supplementary-groups '("video" "input"))
(terminals
(map (lambda (x)
(greetd-terminal-configuration
(terminal-vt (number->string x))
(terminal-switch (eqv? 1 x))
(default-session-command
(cond
((eqv? 1 x)
(greetd-tuigreet-session))
(else
(greetd-agreety-session
(command
(greetd-user-session
(command #~(getenv "SHELL"))))))))))
(iota 6 1)))))
(service bluetooth-service-type
(define %rosenthal-desktop-services-gdm
(cons* (service bluetooth-service-type
(bluetooth-configuration
(auto-enable? #t)))
@ -706,17 +678,45 @@ configuration {
(simple-service 'backlight udev-service-type (specs->pkgs "light"))
(modify-services %desktop-services
(delete mingetty-service-type)
(delete %display-manager-service-type)
(delete screen-locker-service-type)
;; Use a font suitable for HiDPI monitors.
(console-font-service-type
_ => (map (lambda (num)
(cons (string-append "tty" (number->string num))
%term-font))
(file-append (spec->pkg "font-terminus")
"/share/consolefonts/ter-132n")))
(iota 6 1))))))
(define* (rosenthal-desktop-services-for-system
#:optional (system (or (%current-target-system)
(%current-system))))
(define %display-manager-service-type
(if (string-prefix? "x86_64" system)
gdm-service-type
sddm-service-type))
(cons* (service greetd-service-type
(greetd-configuration
(greeter-supplementary-groups '("video" "input"))
(terminals
(map (lambda (x)
(greetd-terminal-configuration
(terminal-vt (number->string x))
(terminal-switch (eqv? 1 x))
(default-session-command
(cond
((eqv? 1 x)
(greetd-tuigreet-session))
(else
(greetd-agreety-session
(command
(greetd-user-session
(command #~(getenv "SHELL"))))))))))
(iota 6 1)))))
(modify-services %rosenthal-desktop-services-gdm
(delete mingetty-service-type)
(delete %display-manager-service-type))))
(define-syntax %rosenthal-desktop-services
(identifier-syntax (rosenthal-desktop-services-for-system)))