Service emacs (not yet working) + elogind sleep fix (couldn't test)

This commit is contained in:
Aleksandr Lebedev 2025-11-06 22:21:14 +01:00
parent bd1f1ee81e
commit b5f7a5be75
5 changed files with 104 additions and 5 deletions

View file

@ -1,5 +1,6 @@
(define-module (guix-config system base-system)
#:use-module (gnu)
#:use-module (gnu services dbus)
#:use-module (guix)
#:export (base-system))
@ -7,7 +8,25 @@
(define %my-desktop-services
(modify-services %desktop-services
(delete gdm-service-type)))
(delete gdm-service-type)
(elogind-service-type config =>
(elogind-configuration
(inherit config)
(suspend-state '("mem"))
(suspend-mode '("s2idle"))))))
(define my-polkit-wheel
(file-union
"my-polkit-wheel"
`(("share/polkit-1/rules.d/00-my-wheel.rules"
,(plain-file
"00-my-wheel.rules"
"polkit.addRule(function(action, subject) {
if (subject.isInGroup(\"wheel\")) {
return polkit.Result.YES
}
});
")))))
(define base-system
(operating-system
@ -25,6 +44,9 @@
(supplementary-groups '("wheel" "netdev" "audio" "video")))
%base-user-accounts))
;; Globally-installed packages.
; (packages (cons %base-packages))
;; Below is the list of system services. To search for available
;; services, run 'guix system search KEYWORD' in a terminal.
(services
@ -36,6 +58,7 @@
(service gnome-keyring-service-type)
(service bluetooth-service-type)
(service power-profiles-daemon-service-type)
(simple-service 'my-polkit-wheel polkit-service-type (list my-polkit-wheel))
(set-xorg-configuration
(xorg-configuration (keyboard-layout keyboard-layout))))
@ -45,7 +68,6 @@
(bootloader (bootloader-configuration
(bootloader grub-bootloader)
(targets '("/dev/vda"))
(terminal-outputs '(console))
(keyboard-layout keyboard-layout)))
(file-systems (cons (file-system