nixos/home/hyprland/ironbar/reference/scripts/ram_info

5 lines
170 B
Plaintext
Raw Normal View History

2023-10-10 20:00:04 +01:00
used="$(free -m | grep Mem: | awk '{ print $3 }')"
shared="$(free -m | grep Mem: | awk '{ print $5 }')"
true_used=$(expr $shared + $used)
echo "$true_used*0.001" | bc -l