I’ve realised that when using KDE I don’t actually use most of the “desktop” features of it and I wanted to try out a window manager. I chose Sway after discussion with a few friends who use Tiling WMs and because I want to use wayland.
Now with swapping my biggest concern was that I do not want to log in to my system via the TTY and manual (or with a script on login) exec sway
. I really much prefer the experience of using a display manager like SDDM.
The issue I’ve encountered is I can’t find any concrete documented way on any kind of forum or documentation that shows how one could do this with home manager. I have tried with my configs, I’ve read the docs for the specific options im using and nothing I do seems to work. I can either use the programs.sway
option in configuration.nix
and that shows up in SDDM, but ignores home manager; Or I can set the configuration.nix
sway to use a null package as the docs say doing that will allow you to use the home-manager versions.
Here’s my configurations:
configuration.nix
services.xserver = {
enable = true;
xkb = {
layout = "au";
variant = "";
};
};
programs.sway.enable = true;
programs.sway.package = null;
services.displayManager = {
enable = true;
SDDM = {
enable = true;
wayland = true;
};
};
security.polkit.enable = true;
home.nix
{ pkgs, ... }:
{
home.username = "misty";
home.homeDirectory = "/home/misty";
imports = [
./sway.nix
];
home.packages = with pkgs; [
fastfetch
];
home.stateVersion = "24.11";
home.shellAliases = {
rebuild = "sudo nixos-rebuild switch --flake .#mistylappytappy";
upgrade = "/home/misty/Documents/nixos-configs && nix flake upgrade && sudo nixos-rebuild switch --flake .#mistylappytappy";
};
programs.home-manager.enable = true;
}
sway.nix
{ pkgs, ... }: {
wayland.windowManager.sway = {
enable = true;
systemd = {
enable = true;
};
package = pkgs.sway;
config = rec {
modifier = "Mod4";
terminal = "kitty";
startup = [
{command = "fastfetch";}
];
};
};
}
I’m so stuck in figuring this one out so any help would be much appreciated