summaryrefslogtreecommitdiff
path: root/.config/polybar/launch.sh
diff options
context:
space:
mode:
Diffstat (limited to '.config/polybar/launch.sh')
-rwxr-xr-x.config/polybar/launch.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/.config/polybar/launch.sh b/.config/polybar/launch.sh
index c4e683a..791b22d 100755
--- a/.config/polybar/launch.sh
+++ b/.config/polybar/launch.sh
@@ -1,7 +1,12 @@
#!/usr/bin/env bash
+for i in /sys/class/hwmon/hwmon*/temp*_input; do
+ if [ "$(<$(dirname $i)/name): $(cat ${i%_*}_label 2>/dev/null || echo $(basename ${i%_*}))" = "k10temp: Tctl" ]; then
+ export HWMON_PATH="$i"
+ fi
+done
killall -q polybar
echo "---" | tee -a /tmp/polybar1.log
polybar mybar 2>&1 | tee -a /tmp/polybar1.log & disown
- echo "Bar launched"
+echo "Bar launched"