enable swayidle

This commit is contained in:
Leonardo Eugênio 2022-08-01 23:38:27 -03:00
parent 282d2e878e
commit 52278df318

View file

@ -239,9 +239,7 @@ in {
gr = "cd (git root)"; gr = "cd (git root)";
gri = "git rebase --interactive FETCH_HEAD"; gri = "git rebase --interactive FETCH_HEAD";
}; };
functions = { functions = { fish_greeting = ""; };
fish_greeting = "";
};
}; };
programs.zoxide = { programs.zoxide = {
enable = true; enable = true;
@ -575,11 +573,7 @@ in {
unfocused = client bg_color bg_color fg_color bg_color bg_color; unfocused = client bg_color bg_color fg_color bg_color bg_color;
urgent = client alert alert fg_color alert alert; urgent = client alert alert fg_color alert alert;
}; };
output = { output = { "*" = { bg = "${theme.background} fill"; }; };
"*" = {
bg = "${theme.background} fill";
};
};
input."type:touchpad" = { input."type:touchpad" = {
# Disable While Typing # Disable While Typing
dwt = "disabled"; dwt = "disabled";
@ -736,6 +730,24 @@ in {
terminal = pkgs.alacritty.executable; terminal = pkgs.alacritty.executable;
}; };
}; };
services.swayidle = {
enable = true;
timeouts = [
{
timeout = 360;
command = "swaylock -f";
}
{
timeout = 1800;
command = "mpc status | grep \"^\[playing\]\" > /dev/null || swaymsg \"output * dpms off\"";
resumeCommand = "swaymsg \"output * dpms on\"";
}
];
events = [{
event = "before-sleep";
command = "swaylock -f";
}];
};
services.gammastep = { services.gammastep = {
enable = true; enable = true;
provider = "geoclue2"; provider = "geoclue2";