mirror of
https://github.com/zoriya/flake.git
synced 2026-08-15 18:43:42 +00:00
Add hypridle
This commit is contained in:
@@ -104,6 +104,7 @@ in {
|
||||
"Super X" = "spawn '${screenshot}/bin/screenshot'";
|
||||
"Super B" = "spawn '${pkgs.hyprpicker}/bin/hyprpicker | wl-copy'";
|
||||
"Super V" = "spawn '${cliphist} list | rofi -dmenu -display-columns 2 | ${cliphist} decode | wl-copy'";
|
||||
"Super+Shift L" = "spawn 'loginctl lock-session'";
|
||||
}
|
||||
// common_binds;
|
||||
locked = common_binds;
|
||||
|
||||
+20
-3
@@ -21,7 +21,7 @@ in {
|
||||
enable = true;
|
||||
settings = {
|
||||
general = {
|
||||
grace = 10;
|
||||
grace = 3;
|
||||
ignore_emauthpty_input = true;
|
||||
};
|
||||
background = {
|
||||
@@ -47,7 +47,7 @@ in {
|
||||
label = [
|
||||
{
|
||||
monitor = "";
|
||||
text = ''cmd[update:1000] echo "<b><big> $(date +"%H:%M") </big></b>"'';
|
||||
text = ''cmd[update:1000] echo "<b><big> $(${pkgs.coreutils}/bin/date +"%H:%M") </big></b>"'';
|
||||
color = "#ff0000";
|
||||
|
||||
font_size = 64;
|
||||
@@ -60,7 +60,7 @@ in {
|
||||
|
||||
{
|
||||
monitor = "";
|
||||
text = ''cmd[update:18000000] echo "<b> "$(date +'%A, %-d %B %Y')" </b>"'';
|
||||
text = ''cmd[update:18000000] echo "<b> "$(${pkgs.coreutils}/bin/date +'%A, %-d %B %Y')" </b>"'';
|
||||
color = "#ff0000";
|
||||
|
||||
font_size = 24;
|
||||
@@ -73,4 +73,21 @@ in {
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
services.hypridle = {
|
||||
enable = true;
|
||||
settings = {
|
||||
general = {
|
||||
lock_cmd = "${pkgs.procps}/bin/pidof hyprlock || ${pkgs.hyprlock}/bin/hyprlock";
|
||||
before_sleep_cmd = "${pkgs.systemd}/bin/loginctl lock-session";
|
||||
};
|
||||
|
||||
listener = [
|
||||
{
|
||||
timeout = 1800;
|
||||
on-timeout = "${pkgs.procps}/bin/pidof hyprlock && ${pkgs.systemd}/bin/systemctl suspend";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user