Add swaylock stuff
This commit is contained in:
@@ -30,6 +30,50 @@ in
|
||||
nerd-fonts.jetbrains-mono
|
||||
];
|
||||
|
||||
programs.swaylock = {
|
||||
enable = true;
|
||||
package = pkgs.swaylock-effects;
|
||||
settings = {
|
||||
clock = true;
|
||||
color = base;
|
||||
effect-pixelate = 50;
|
||||
effect-greyscale = true;
|
||||
screenshots = true;
|
||||
font = "JetBrainsMono Nerd Font";
|
||||
font-size = 24;
|
||||
indicator-idle-visible = true;
|
||||
indicator-radius = 200;
|
||||
indicator-thickness = 17;
|
||||
line-color = base;
|
||||
ring-color = overlay0;
|
||||
inside-color = base;
|
||||
key-hl-color = lavender;
|
||||
separator-color = base;
|
||||
text-color = text;
|
||||
text-caps-lock-color = text;
|
||||
line-ver-color = base;
|
||||
ring-ver-color = lavender;
|
||||
inside-ver-color = base;
|
||||
text-ver-color = text;
|
||||
ring-wrong-color = red;
|
||||
text-wrong-color = red;
|
||||
inside-wrong-color = base;
|
||||
inside-clear-color = base;
|
||||
text-clear-color = text;
|
||||
ring-clear-color = yellow;
|
||||
line-clear-color = base;
|
||||
line-wrong-color = base;
|
||||
bs-hl-color = red;
|
||||
grace = 2;
|
||||
grace-no-mouse = true;
|
||||
grace-no-touch = true;
|
||||
datestr = "%a, %B %e";
|
||||
timestr = "%H:%M";
|
||||
fade-in = 0.3;
|
||||
ignore-empty-password = true;
|
||||
};
|
||||
};
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
package = pkgs.swayfx;
|
||||
@@ -106,7 +150,7 @@ in
|
||||
startup = [
|
||||
{ command = "waybar"; }
|
||||
{ command = "mako"; }
|
||||
{ command = "swayidle -w timeout 300 'swaylock -f -c 000000' timeout 600 'swaymsg \"output * dpms off\"' resume 'swaymsg \"output * dpms on\"' before-sleep 'swaylock -f -c 000000'"; }
|
||||
{ command = "swayidle -w timeout 300 'swaylock -f' timeout 600 'swaymsg \"output * dpms off\"' resume 'swaymsg \"output * dpms on\"' timeout 900 'systemctl suspend' before-sleep 'swaylock -f'"; }
|
||||
];
|
||||
|
||||
keybindings = let
|
||||
@@ -118,11 +162,11 @@ in
|
||||
"${modifier}+Shift+c" = "reload";
|
||||
"${modifier}+Shift+e" = "exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -B 'Yes, exit sway' 'swaymsg exit'";
|
||||
|
||||
"${modifier}+Shift+l" = "exec swaylock -f -c 000000";
|
||||
"${modifier}+Shift+l" = "exec swaylock -f";
|
||||
|
||||
"${modifier}+Shift+s" = "exec grim -g \"$(slurp)\" - | wl-copy";
|
||||
|
||||
# Workspace cycling with mouse
|
||||
# Workspaces
|
||||
"--whole-window ${modifier}+button4" = "workspace prev";
|
||||
"--whole-window ${modifier}+button5" = "workspace next";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user