Memory: [Haiku] Simpler memory command

This commit is contained in:
Dylan Araps 2016-11-05 12:03:00 +11:00
parent 3eea0891e0
commit 306fe9caa6

View file

@ -1125,7 +1125,7 @@ getmemory() {
;;
"Haiku")
memtotal=$(($(sysinfo -mem | head -n1 | cut -d'/' -f3 | tr -d ' ' | tr -d ')') / 1024 / 1024))
memtotal="$(($(sysinfo -mem | awk -F '\\/ |)' '{print $2; exit}') / 1024 / 1024))"
memused="$(sysinfo -mem | awk -F '\\/|)' '{print $2; exit}')"
memused="$((${memused/max} / 1024 / 1024))"
;;