mirror of
https://git.disroot.org/FollieHiyuki/dotfiles.git
synced 2024-12-05 05:38:21 -05:00
8 lines
204 B
Bash
Executable File
8 lines
204 B
Bash
Executable File
#!/bin/sh
|
|
|
|
mem=$(free -k | grep "Mem")
|
|
memtotal=$(echo "$mem" | awk -F' ' '{ print $2 }')
|
|
memavail=$(echo "$mem" | awk -F' ' '{ print $7 }')
|
|
ramu=$(( 100*(memtotal-memavail)/memtotal ))
|
|
echo "異 $ramu%"
|