help-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Could anyone using EXWM share their guix config?


From: Oleander
Subject: Re: Could anyone using EXWM share their guix config?
Date: Wed, 25 Sep 2024 16:48:18 +0000

Hi Jordan, Arne, Ian and thanks for your support. 

On Sunday, September 15th, 2024 at 6:39 PM, indieterminacy 
<indieterminacy@libre.brussels> wrote:

> Ive been having a go at this myself over the weekend but admittedly I
> havent resolved it yet (my screen and keyboard froze).
> 
> Ive been hacking from these two configs (the second of which uses SX,
> rather than Startx):
> https://github.com/jsoo1/dotfiles/blob/release/guix/config.scm
> https://codeberg.org/tuff-engin/GuixConfigurationSkeleton
> 
> I had recalled some mails regarding advances.
> It seems that Tomas Volf's patches have made the procedure more
> tangible:
> https://issues.guix.gnu.org/68289
> https://git.savannah.gnu.org/cgit/guix.git/commit/gnu/services/xorg.scm?id=9948816819e0af23587d75701ba81d797ef7ea29
> https://git.savannah.gnu.org/cgit/guix.git/commit/gnu/services/xorg.scm?id=e51a930c5c5a8609b8656bf997ec853cc04391e7
> https://git.savannah.gnu.org/cgit/guix.git/commit/gnu/home/services/desktop.scm?id=8144c587f89641d5976d5b3832297d391d489fbd
> 
> The documentation is currently only in the branch Devel (I dont know if
> that means it is currently in conventional OSes):
> https://guix.gnu.org/manual/devel/en/html_node/X-Window.html
> https://guix.gnu.org/manual/devel/en/html_node/Desktop-Home-Services.html
> 
> Ill have a go at resolving this but Im only (finally) getting used to
> Home services,
> so I may take some wrong paths.
> 
> I find it a little disapointing that there arent examples for this
> functionality,
> so that somebody can dive in without being an expert.
> Even a pointer to a dotfiles with the new functionality would be swell.
> 
> Hopefully Ill resolve my own misunderstanding soon.
> 
> Hopefully I merely need to write a config file and then point to it.
> 
> Should this info help Id love to examine your config(s)!
> 
> I do love EXWM though and cherish avoid GUIs to login (and all the cruft
> those setups entail) -- dont lose hope, its worth it!
> 
> Kind regards,
> 
> 
> Jonathan


I've been using this system config [1] so far and it works ok but it's still 
not the (almost) perfect setup I run with Sway.

I'd prefer to avoid installing all the dependencies that come with GDM (mutter, 
gnome-control-center, gnome shell, ecc.) but I could live with that until we 
can come up with something better.

I still haven't figured out:

- how to start udiskie automatically at boot.
With Sway `exec udiskie` was enough. I think this is also possible with a Guix 
service but I haven't had much time to mess with the code. 

- how to set up a keybinding to toggle two different keyboard layouts. With 
Sway I had to add `xkb_options grp:shift_caps_toggle` to the input code.

- how to take screenshots and enable notifications in xorg without a desktop 
environment. With Sway I used grim and mako.

- how to make Emacs PDFs not appear blurry, It was the same with Sway, but 
never figured out how to fix it. 

Unfortunately, before switching to Sway I only used xorg with DEs and  I have 
no experience with the X config files.

[1]
;; System config
(use-modules
 (gnu) (gnu system))
(use-service-modules
 dbus desktop networking sound ssh xorg)
(use-package-modules
 admin bootloaders certs emacs emacs-xyz glib screen ssh video wm xorg)

(operating-system
 (host-name "t420")
 (timezone "Europe/Rome")
 (locale "en_US.utf8")
 (keyboard-layout (keyboard-layout "us"))

 (bootloader
   (bootloader-configuration
    (bootloader grub-bootloader)
    (targets '("/dev/sda"))
    (terminal-outputs '(console))))

 (kernel-arguments
  (cons* "intel_idle.max_cstate=2"
         %default-kernel-arguments))
 
 ;; Specify a mapped device for the encrypted root partition.
 ;; The UUID is that returned by 'cryptsetup luksUUID'.
 (mapped-devices
  (list (mapped-device
         (source (uuid "e4a3dcf5-c421-3157-61er-5fy712450j4t"))
         (targets (list "guix"))
         (type luks-device-mapping))))

 (file-systems
  (append
   (list (file-system
          (device (file-system-label "guix"))
          (mount-point "/")
          (type "ext4")
          (dependencies mapped-devices)))
   %base-file-systems))

 (swap-devices
   (list
    (swap-space (target "/swapfile"))))

 (users
  (cons (user-account
         (name "oleander")
         (comment "")
         (group "users")
         (home-directory "/home/oleander")
         (supplementary-groups '("wheel" "netdev"
                                 "audio" "video" "input")))
        %base-user-accounts))

 ;; System-wide packages.
 (packages
  (append
   (list
    dbus
    intel-vaapi-driver
    libva-utils
    openssh-sans-x
    screen
    emacs emacs-exwm emacs-desktop-environment
    wpa-supplicant
    xorg-server)
   %base-packages))

 (services
  (cons*
   (set-xorg-configuration
    (xorg-configuration
     (keyboard-layout keyboard-layout)
     (extra-config
      '("Section \"InputClass\"\n"
        "  Identifier \"libinput touchpad catchall\"\n"
        "  Driver \"libinput\"\n"
        "  MatchIsTouchpad \"on\"\n"
        "  MatchDevicePath \"/dev/input/event*\"\n"
        "  Option \"Tapping\" \"on\"\n"
        "  Option \"TappingDrag\" \"on\"\n"
        "  Option \"DisableWhileTyping\" \"on\"\n"
        "EndSection\n"
        "\n"
     
        ; https://wiki.archlinux.org/title/Libinput#Via_xinput
        "Section \"InputClass\"\n"
        "  Identifier \"USB Mouse Pad USB Mouse Pad Mouse\"\n"
        "  Driver \"libinput\"\n"
        "  Option \"Middle Emulation\" \"on\"\n"
        "  Option \"AccelSpeed\"  \"1.0\""
        "EndSection\n"
        "\n"
        "\n"
        "Section \"Device\"\n"
        "  Identifier \"Intel Graphics\"\n"
        "  Driver \"intel\"\n"
        "  Option \"TearFree\" \"True\"\n"
        "  Option \"DRI\" \"2\"\n"
        "  Option \"AccelMethod\" \"sna\"\n"
        "EndSection"
        "\n"))))
   (modify-services %desktop-services
                    (gdm-service-type
                     config => (gdm-configuration
                                (auto-login? #t)
                                (default-user "oleander"))))))

 ;; Allow resolution of '.local' host names with mDNS.
 (name-service-switch %mdns-host-lookup-nss))







reply via email to

[Prev in Thread] Current Thread [Next in Thread]