mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-12-24 12:32:32 +00:00
Add memory support to iOS
This commit is contained in:
6
neofetch
6
neofetch
@@ -1232,7 +1232,7 @@ getmemory () {
|
||||
memtotal=$((mem[0] / 1024))
|
||||
;;
|
||||
|
||||
"Mac OS X")
|
||||
"Mac OS X" | "iPhone OS")
|
||||
memtotal=$(printf "%s\n" "$(sysctl -n hw.memsize)"/1024^2 | bc)
|
||||
memwired=$(vm_stat | awk '/wired/ { print $4 }')
|
||||
memactive=$(vm_stat | awk '/active / { printf $3 }')
|
||||
@@ -1240,10 +1240,6 @@ getmemory () {
|
||||
memused=$(((${memwired//.} + ${memactive//.} + ${memcompressed//.}) * 4 / 1024))
|
||||
;;
|
||||
|
||||
"iPhone OS")
|
||||
memtotal=$(printf "%s\n" "$(sysctl -n hw.memsize)"/1024^2 | bc)
|
||||
;;
|
||||
|
||||
"OpenBSD" | "BSD")
|
||||
case "$distro" in
|
||||
"OpenBSD"*)
|
||||
|
||||
Reference in New Issue
Block a user