mirror of
https://github.com/tiyn/dotfiles.git
synced 2025-10-09 19:11:15 +02:00
statusbar: split cpu and gpu temps
This commit is contained in:
12
.local/bin/tools/statusbar/gpu
Executable file
12
.local/bin/tools/statusbar/gpu
Executable file
@@ -0,0 +1,12 @@
|
||||
#!/bin/sh
|
||||
|
||||
icon="^b#282828^^c#dfdfdf^ ^d^"
|
||||
|
||||
temp=""
|
||||
|
||||
if command -v nvidia-smi > /dev/null; then
|
||||
temp=$(nvidia-smi --query-gpu=temperature.gpu --format=csv,noheader)
|
||||
temp=$(printf %3s $(echo ${temp##*+} | sed "s/\..*//") | tr ' ' ' ')
|
||||
fi
|
||||
|
||||
echo "$icon $temp°C"
|
Reference in New Issue
Block a user