Add 2 dummy numbers to mem function
This commit is contained in:
parent
e2ae78c898
commit
f358f25e8a
1 changed files with 1 additions and 2 deletions
3
neofetch
3
neofetch
|
@ -1,5 +1,4 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -x
|
|
||||||
# vim: fdm=marker:noai:ts=4:sw=4
|
# vim: fdm=marker:noai:ts=4:sw=4
|
||||||
#
|
#
|
||||||
# Neofetch info about your system
|
# Neofetch info about your system
|
||||||
|
@ -1091,7 +1090,7 @@ getgpu () {
|
||||||
getmemory () {
|
getmemory () {
|
||||||
case "$os" in
|
case "$os" in
|
||||||
"Linux" | "Windows")
|
"Linux" | "Windows")
|
||||||
mem=($(awk -F ':| kB' '/MemTotal|MemFree|Buffers|Cached/ {printf $2}' /proc/meminfo ))
|
mem=($(awk -F ':| kB' '/MemTotal|MemFree|Buffers|Cached/ {printf $2}' /proc/meminfo ) 0 0)
|
||||||
memused=$((${mem[0]} - ${mem[1]} - ${mem[2]} - ${mem[3]}))
|
memused=$((${mem[0]} - ${mem[1]} - ${mem[2]} - ${mem[3]}))
|
||||||
memused=$((memused / 1024))
|
memused=$((memused / 1024))
|
||||||
memtotal=$((${mem[0]} / 1024))
|
memtotal=$((${mem[0]} / 1024))
|
||||||
|
|
Loading…
Reference in a new issue