How to run window-manager only (no DE)

I switched away from Gnome a while ago, preferring to use a window manager without any desktop environment. But I kept Gnome around during the transition, so my NixOS configuration contains,

services.xserver.desktopManager.gnome3.enable = true;
services.xserver.windowManager.xmonad.enable = true;

Now I’d like to drop Gnome completely (I can’t remember the last time I logged into it), but there are several nixos options and systemd services currently enabled because gnome3 is enabled.

I’m trying to figure out which things I rely on, so that I can enable them myself and disable gnome3. Some of them are things I’m familiar with, like pulseaudio and networkmanager, but many others are less familiar, like dconf, polkit, accounts-daemon, xdg.portal, etc. Link

Can anyone point me in the right direction on this quest? I’m considering, as a starting point, explicitly enabling all the options/services/packages that gnome3 currently enables, and gradually disabling things, seeing what (if anything) breaks, and finding solutions/alternatives as needed.

It would be helpful to read about anyone else’s experience doing something similar though, regardless of the linux distro.

1 Like

you should be able to remove services.xserver.desktopManager.gnome3.enable = true;. You will just have a none+xmonad xsession

Right, that’s my goal. But when I made that change I found that networkmanager and pulseaudio were no longer running, and quickly realized that they had been enabled indirectly as a result of enabling gnome3.

That discovery led me to take a look at all the other things that gnome3 had enabled. Some are gnome-specific things I don’t want to run, but there are quite a few I don’t know enough about to say whether I should enable them or not, such as

programs.dconf.enable
security.polkit.enable
services.accounts-daemon.enable
xdg.portal.enable

I guess what I’m asking is where can I go to fill the gaps in my linux knowlege so I can make an informed decision about which components are required for a coherent and secure system.

That logic can be found here: https://github.com/NixOS/nixpkgs/blob/90d95d451393d46712ebac906c13d1cdbd43de5a/nixos/modules/services/x11/desktop-managers/gnome3.nix#L196

A little hard to read, and modules work transitively; so gnome3 may not mention pulseaudio directly, but another configuration setting may cause it to change.