aboutsummaryrefslogtreecommitdiff
path: root/Scripts
diff options
context:
space:
mode:
authorAryadev Chavali <aryadev@aryadevchavali.com>2023-06-26 10:25:46 +0100
committerAryadev Chavali <aryadev@aryadevchavali.com>2023-07-14 19:54:39 +0100
commitbb1cdfface330c6585fa694254397c8b58351dd5 (patch)
treefcb5d528f6a19731b978d77611551b9d28db2145 /Scripts
parent020edafda501ed30d4bc490bf727a75c8ae042f7 (diff)
downloaddotfiles-bb1cdfface330c6585fa694254397c8b58351dd5.tar.gz
dotfiles-bb1cdfface330c6585fa694254397c8b58351dd5.tar.bz2
dotfiles-bb1cdfface330c6585fa694254397c8b58351dd5.zip
(Scripts>status)+Emacs memory to status script
Diffstat (limited to 'Scripts')
-rwxr-xr-xScripts/.local/scripts/status/memory3
1 files changed, 2 insertions, 1 deletions
diff --git a/Scripts/.local/scripts/status/memory b/Scripts/.local/scripts/status/memory
index ecdfc0e..8ae6baf 100755
--- a/Scripts/.local/scripts/status/memory
+++ b/Scripts/.local/scripts/status/memory
@@ -4,4 +4,5 @@ line=$(free -m | sed -n 2p);
used=$(echo $line | awk '{print $3}');
available=$(echo $line | awk '{print $2}');
value=$(echo "100 * $used / $available" | bc -l | xargs printf "%.2f" $1)
-echo " $(printf "%dMB" $used) $value%"
+emacs=$(systemctl --user status emacs | grep "Memory: " | sed "s/[ ]*//;s/Memory: //")
+echo " $(printf "%dMB" $used) $value% ->  $emacs"