I have a bunch of issues with GDM.
I have set my default desktop session to KDE (Mainly that my wife will get the right default)
services.xserver = {
enable = true;
displayManager = {
defaultSession = "plasmawayland";
gdm = {
enable = true;
wayland = true;
};
};
};
GDM is supposed to remember a users session choice. But that information does not survive a reboot. So GDM will always default back to KDE even for me.
I had a quick look, it seems like GDM is sourcing xsession files
see /etc/gdm/Xsession
# Allow the user to setup a custom session type.
if test -x ~/.xsession; then
eval exec ~/.xsession "$@"
fi
So the solution seemed obvious. I use home-manager to set
xsession.windowManager.command = "exec Hyprland";
I get a nice ~/.xsession file. But my default desktop session is still KDE.