diff --git a/home/dot_config/sway/scripts/executable_status.sh.tmpl b/home/dot_config/sway/scripts/executable_status.sh.tmpl
index 20f758e9..c68d80ed 100644
--- a/home/dot_config/sway/scripts/executable_status.sh.tmpl
+++ b/home/dot_config/sway/scripts/executable_status.sh.tmpl
@@ -18,9 +18,8 @@ else
fi
# Volume
-sink=$(pactl list short sinks | grep 'RUNNING\|IDLE' | awk '{print $1}')
-#sink=$( pactl list short sinks | sed -e 's,^\([0-9][0-9]*\)[^0-9].*,\1,' | head -n 2 | tail -n 1)
-volume=$( pactl list sinks | grep '^[[:space:]]Volume:' | head -n $(( $sink + 1 )) | tail -n 1 | sed -e 's,.* \([0-9][0-9]*\)%.*,\1,' )
+volume=$(pactl list sinks | grep '^[[:space:]]Volume:' | \
+ head -n $(( $SINK + 1 )) | tail -n 1 | sed -e 's,.* \([0-9][0-9]*\)%.*,\1,')
mute=$(pactl list sinks | grep '^[[:space:]]Mute:' | head -n $(( $sink + 1 )) | tail -n 1 | awk '{print $2}')
if [ "$mute" == "yes" ]; then
@@ -30,7 +29,7 @@ else
fi
#bluetooth=$(bluetoothctl devices | cut -f2 -d' ' | while read uuid; do bluetoothctl info $uuid; done | grep -e "Name\|Connected: yes" | grep -B1 "yes" | head -n 1 | cut -d\ -f2-)
-bluetooth="🫐"
+#bluetooth="🫐"
# Network usage
r1=`cat /sys/class/net/{{ .network_interface }}/statistics/rx_bytes`
@@ -50,5 +49,13 @@ else
vpn="none"
fi
+# Logitech mouse battery status
+bat=$(cat /sys/class/power_supply/hidpp_battery_0/capacity)
+if [ $bat -lt 20 ]; then
+ bat_color="#f92672"
+else
+ bat_color="#ffffff"
+fi
+
#lel
-echo -e "👍 $txmb 👎 $rxmb | 📡 $vpn | ⬆️ $uptime_formatted | 🔉$volume% | $gamemode | 🐧 $linux_version | $date_formatted "
+echo -e "👍 $txmb 👎 $rxmb | 📡 $vpn | ⬆️ $uptime_formatted | 🔉$volume% | 🐁$bat% | $gamemode | 🐧 $linux_version | $date_formatted "
diff --git a/provision/nixos/modules/services/peripherals.nix b/provision/nixos/modules/services/peripherals.nix
index ac69fd04..74dd1da6 100644
--- a/provision/nixos/modules/services/peripherals.nix
+++ b/provision/nixos/modules/services/peripherals.nix
@@ -5,6 +5,10 @@ in {
options.modules.services.peripherals.enable = lib.mkEnableOption "peripherals";
config = lib.mkIf cfg.enable {
+ environment.systemPackages = with pkgs; [
+ pulseaudio
+ ];
+
# rtkit is optional but recommended
security.rtkit.enable = true;
services.pipewire = {
@@ -12,8 +16,6 @@ in {
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
- # If you want to use JACK applications, uncomment this
- #jack.enable = true;
};
services = {