diff --git a/config/sway/config b/config/sway/config index 31acc6d..52be7a0 100644 --- a/config/sway/config +++ b/config/sway/config @@ -115,6 +115,9 @@ mode "resize" { } bindsym $mod+r mode "resize" +# Autologin via greetd (hosts/la2410/configuration.nix) -- this lock is the login. +exec swaylock -e -c 000000 + exec { waybar kanshi diff --git a/hosts/la2410/configuration.nix b/hosts/la2410/configuration.nix index 40d7496..88477b8 100644 --- a/hosts/la2410/configuration.nix +++ b/hosts/la2410/configuration.nix @@ -272,18 +272,21 @@ pulse.enable = true; }; -services.displayManager.ly = { +# Boot straight into sway as shihaam; sway locks itself on startup (see the +# swaylock exec in config/sway/config), so the swaylock password is the login. +# initial_session only fires once per boot -- after logging out of sway, +# greetd falls back to default_session, a normal tuigreet login. +services.greetd = { enable = true; settings = { -# auto_login_user = "shihaam"; -# auto_login_session = "sway"; -# auto_login_service = "ly-autologin"; - animation = "matrix"; - bigclock = "en"; - asterisk = null; - battery_id = "BAT0"; - brightness_up_cmd = "${pkgs.brightnessctl}/bin/brightnessctl -q -n s +10%"; - brightness_down_cmd = "${pkgs.brightnessctl}/bin/brightnessctl -q -n s 10%-"; + initial_session = { + command = "sway"; + user = "shihaam"; + }; + default_session = { + command = "${pkgs.tuigreet}/bin/tuigreet --time --asterisks --cmd sway"; + user = "greeter"; + }; }; }; #boot.kernelModules = [ "i2c-dev" ];