dotfiles/.local/bin/statusbar/sb-memory
2024-05-17 20:46:22 -04:00

6 lines
128 B
Bash
Executable file

#!/bin/sh
memory=$(free -h | awk '/Mem/ {printf "%s/%s\n", $3, $2}' | sed 's/Gi/G/g; s/Mi/M/g')
printf '[MEM %s]\n' "$memory"