From 4ddc7dc0b5e50caa41cd122744057fb33de1f1d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=20Houl=C3=A9?= Date: Sun, 30 Jan 2022 09:58:51 +0100 Subject: [PATCH] Clean up swaylock configuration In the process of figuring out what happened. Turns out it's a breaking change in pam management in nixos unstable. Tracking issue: https://github.com/NixOS/nixpkgs/issues/157112 --- hm/tom/modules/sway/config | 6 +++--- hm/tom/modules/sway/default.nix | 1 + hm/tom/modules/sway/swaylock-config | 5 +++++ 3 files changed, 9 insertions(+), 3 deletions(-) create mode 100644 hm/tom/modules/sway/swaylock-config diff --git a/hm/tom/modules/sway/config b/hm/tom/modules/sway/config index 5d2509c..dca3f93 100644 --- a/hm/tom/modules/sway/config +++ b/hm/tom/modules/sway/config @@ -41,9 +41,9 @@ output * bg ~/.config/sway/wallpaper fill # your displays after another 300 seconds, and turn your screens back on when # resumed. It will also lock your screen before your computer goes to sleep. exec swayidle -w \ - timeout 300 'swaylock -f -c 000000' \ + timeout 300 'swaylock' \ timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \ - before-sleep 'swaylock -f -c 000000' + before-sleep 'swaylock' ### Input configuration # @@ -106,7 +106,7 @@ seat seat0 xcursor_theme whiteglass bindsym XF86MonBrightnessDown exec brillo -U 10 # Lock - bindsym $mod+Ctrl+l exec swaylock -c 010100 -i ~/.config/sway/wallpaper + bindsym $mod+Ctrl+l exec swaylock # Screenshots bindsym Print exec grim -t png -g "$(slurp)" ~/Pictures/$(date +%Y-%m-%d_%H-%m-%S).png; diff --git a/hm/tom/modules/sway/default.nix b/hm/tom/modules/sway/default.nix index 5114f98..1a65bbd 100644 --- a/hm/tom/modules/sway/default.nix +++ b/hm/tom/modules/sway/default.nix @@ -25,5 +25,6 @@ in ''; "waybar".source = config.localHome.waybarConfigDir; + "swaylock/config".source = ./swaylock-config; }; } diff --git a/hm/tom/modules/sway/swaylock-config b/hm/tom/modules/sway/swaylock-config new file mode 100644 index 0000000..ce11206 --- /dev/null +++ b/hm/tom/modules/sway/swaylock-config @@ -0,0 +1,5 @@ +color=010100 +image=~/.config/sway/wallpaper +daemonize +show-keyboard-layout +indicator-caps-lock