From e40d0e1f047fa7f6d135154e59aea0b7e72184e3 Mon Sep 17 00:00:00 2001 From: Julian T Date: Mon, 8 Jul 2019 20:41:25 +0200 Subject: Added i3wm config --- i3/Scripts/ram.sh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 i3/Scripts/ram.sh (limited to 'i3/Scripts/ram.sh') diff --git a/i3/Scripts/ram.sh b/i3/Scripts/ram.sh new file mode 100644 index 0000000..b0c2442 --- /dev/null +++ b/i3/Scripts/ram.sh @@ -0,0 +1,19 @@ +PIDFILE=/tmp/statRam.pid +STATUSFILE=/tmp/dsbRfree + +kill `cat $PIDFILE` +if [ $? -eq 0 ]; then + echo "Shutting down" + rm $STATUSFILE + exit +fi + +echo "Starting up" + +echo $$ > $PIDFILE + +while true; do + echo " $(free -h | grep Mem: | awk '{print $3}') " > $STATUSFILE + sleep 2 +done + -- cgit v1.2.3