From 93b29402a45486d3dc5bc8f30393bc4107a43dc6 Mon Sep 17 00:00:00 2001 From: Jimbo Date: Tue, 3 Sep 2024 19:22:06 -0400 Subject: [PATCH] Do the swaylock thing from before but better --- home-manager/sway/autostart.nix | 3 --- home-manager/sway/swaylock.nix | 5 +++++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/home-manager/sway/autostart.nix b/home-manager/sway/autostart.nix index 08ab834..1c727c3 100644 --- a/home-manager/sway/autostart.nix +++ b/home-manager/sway/autostart.nix @@ -6,9 +6,6 @@ bars = [{command = "waybar";}]; startup = [ - # Lock the screen on start, to allow an autostarted session - {command = "swaylock";} - # Scratchpads {command = "foot -a gotop -T Gotop gotop";} {command = "foot -a music -T Music ncmpcpp";} diff --git a/home-manager/sway/swaylock.nix b/home-manager/sway/swaylock.nix index c1cf348..91eefa5 100644 --- a/home-manager/sway/swaylock.nix +++ b/home-manager/sway/swaylock.nix @@ -58,4 +58,9 @@ in { home.packages = with pkgs; [ swayLock ]; + + # Enable Sway lock on startup + wayland.windowManager.sway.config.startup = [ + {command = "swaylock";} + ]; }