adding idk things

This commit is contained in:
Chris Cochrun 2021-08-25 05:13:50 -05:00
parent e75be2bdfa
commit bb7a0dc58e
3 changed files with 24 additions and 0 deletions

10
scripts/mem-plasma.2s.sh Executable file
View file

@ -0,0 +1,10 @@
#!/bin/bash
# Get the percentage of used memory and print it
read used total <<< $(free -m | awk '/Mem/{printf $2" "$3}')
percent=$(bc -l <<< "100 * $total / $used")
mem=$(awk -v u=$used -v t=$total -v p=$percent 'BEGIN {printf "%sMi/%sMi %.1f% ", t, u, p}'| awk '{printf $2}')
echo "$mem | color=#ff9f43 font='VictorMono Nerd Font' size=11"