18 lines
638 B
Bash
Executable File
18 lines
638 B
Bash
Executable File
#!/bin/bash
|
|
# dwm status bar
|
|
|
|
ipl=$(ip addr show dev enp7s0 | grep -F 'inet ' | cut -f1 -d/ | awk '{print $2}')
|
|
ipw=$(curl -s ipinfo.io/ip)
|
|
while true
|
|
do
|
|
vol=$(volctl)
|
|
cpu=$(mpstat | grep -F all | awk '{print $13}')
|
|
tmp=$(sensors | grep Tctl | awk '{print $2}' | sed 's/+//')
|
|
dsk=$(df -h / | awk '{print $4}' | grep -E '[0-9]')
|
|
ram=$(free -h | grep -F Mem: | awk '{print $7}')
|
|
gpu=$(nvidia-smi | head -n 10 | tail -n 1 | grep W | awk '{print $5}')
|
|
xsetroot -name " 📢 $vol | 🔌 $gpu | 🛠 $cpu | 🌡$tmp | 🧠 $ram | 💾 $dsk | 🏡 $ipl | 🌎 $ipw | 🗓 $(date '+%A, %d %B %Y - %H:%M:%S %Z ' ) "
|
|
sleep 0.1
|
|
done
|
|
# EOF
|