change for waybar

Signed-off-by: Hadi <112569860+anotherhadi@users.noreply.github.com>
This commit is contained in:
Hadi
2025-08-28 23:11:34 +02:00
parent 9d04654018
commit 4f9ea610d6
9 changed files with 522 additions and 31 deletions

View File

@@ -17,14 +17,10 @@
caffeine = pkgs.writeShellScriptBin "caffeine" ''
if [[ $(pidof "hypridle") ]]; then
systemctl --user stop hypridle.service
title="󰅶 Caffeine Activated"
description="Caffeine is now active! Your screen will not turn off automatically."
${pkgs.swayosd}/bin/swayosd-client --custom-message="Caffeine On" --custom-icon="emblem-default"
else
systemctl --user start hypridle.service
title="󰾪 Caffeine Deactivated"
description="Caffeine is now deactivated! Your screen will turn off automatically."
${pkgs.swayosd}/bin/swayosd-client --custom-message="Caffeine Off" --custom-icon="emblem-default"
fi
notif "caffeine" "$title" "$description"
'';
in {home.packages = [caffeine-status caffeine caffeine-status-icon];}