aboutsummaryrefslogtreecommitdiff
path: root/pw-fan
diff options
context:
space:
mode:
Diffstat (limited to 'pw-fan')
-rwxr-xr-xpw-fan10
1 files changed, 10 insertions, 0 deletions
diff --git a/pw-fan b/pw-fan
new file mode 100755
index 0000000..4dea310
--- /dev/null
+++ b/pw-fan
@@ -0,0 +1,10 @@
+#!/usr/bin/env bash
+# requires joypixels font in dwm config.def.h
+
+# Try different fan sensors
+FAN_SPEED=$(sensors | awk '/^fan|^cpu_fan/ {print $2}')
+[ -z "$FAN_SPEED" ] && FAN_SPEED="N/A"
+
+# Send to bar
+echo -e " 🌀 $FAN_SPEED ┊"
+