mirror of
https://github.com/agresdominik/dotfiles.git
synced 2026-04-21 18:05:50 +00:00
New branch + sway settings
This commit is contained in:
Executable
+8
@@ -0,0 +1,8 @@
|
||||
#!/bin/bash
|
||||
mem=$(free -h | awk '/Mem:/ {print $3 "/" $2}')
|
||||
cpu=$(grep 'cpu ' /proc/stat | awk '{usage=($2+$4)*100/($2+$4+$5)} END {printf "%.1f%%", usage}')
|
||||
bat=$(cat /sys/class/power_supply/macsmc-battery/capacity 2>/dev/null || echo "N/A")
|
||||
time=$(date "+%d.%m %H:%M:%S")
|
||||
|
||||
echo "CPU: $cpu | MEM: $mem | BAT: $bat% | $time"
|
||||
|
||||
Reference in New Issue
Block a user