This commit is contained in:
Hadi
2024-06-27 19:42:08 +02:00
parent ae6818ed65
commit 84f87f9833
13 changed files with 138 additions and 95 deletions

View File

@@ -17,4 +17,13 @@ let
notif "caffeine" "$message"
'';
in { home.packages = [ caffeine-status caffeine ]; }
caffeine-status-icon = pkgs.writeShellScriptBin "caffeine-status-icon" ''
status=$(caffeine-status)
if [[ $status == "active" ]]; then
echo "󰅶"
else
echo "󰾪"
fi
'';
in { home.packages = [ caffeine-status caffeine caffeine-status-icon ]; }

View File

@@ -24,11 +24,27 @@ let
'';
night-shift-status = pkgs.writeShellScriptBin "night-shift-status" ''
if pgrep wlsunset; then
if [[ $(pgrep wlsunset) ]]; then
echo "1"
else
echo "0"
fi
'';
in { home.packages = [ night-shift-on night-shift-off night-shift-toggle night-shift-status ]; }
night-shift-status-icon =
pkgs.writeShellScriptBin "night-shift-status-icon" ''
if [[ $(pgrep wlsunset) ]]; then
echo "󰖔"
else
echo "󰖕"
fi
'';
in {
home.packages = [
night-shift-on
night-shift-off
night-shift-toggle
night-shift-status
night-shift-status-icon
];
}