diff options
author | Blaster4385 <[email protected]> | 2025-08-15 15:09:35 +0530 |
---|---|---|
committer | Blaster4385 <[email protected]> | 2025-08-15 15:09:35 +0530 |
commit | 5690fffa9360180dcf79738cde27b918e09e6273 (patch) | |
tree | b999d0a1f875791652bcec1a80ad8d575ad55d9a /waybar/custom_modules/custom-gpu-lite.sh | |
parent | addbb7a93bf327b3f4f445805722039df457c145 (diff) |
Diffstat (limited to 'waybar/custom_modules/custom-gpu-lite.sh')
-rwxr-xr-x | waybar/custom_modules/custom-gpu-lite.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/waybar/custom_modules/custom-gpu-lite.sh b/waybar/custom_modules/custom-gpu-lite.sh new file mode 100755 index 0000000..d2821c1 --- /dev/null +++ b/waybar/custom_modules/custom-gpu-lite.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +raw_temp=$(cat /sys/class/drm/card0/device/hwmon/hwmon5/temp1_input) +temperature=$(($raw_temp/1000)) +deviceinfo=$(glxinfo -B | grep 'Device:' | sed 's/^.*: //') +driverinfo=$(glxinfo -B | grep "OpenGL version") + +echo '{"text": " '$temperature'°C", "class": "custom-gpu", "tooltip": "<b>'$deviceinfo'</b>\n'$driverinfo'"}'
\ No newline at end of file |