From 7f9a4aa11d5177cd4f3efcd359b84485408747ba Mon Sep 17 00:00:00 2001 From: Derek Stevens Date: Fri, 2 Oct 2020 14:09:10 -0400 Subject: [PATCH] add a little documentation and give a spartan default while letting '-x' flag print random hex bytes --- desks.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/desks.sh b/desks.sh index c2a5fb8..f5f0da9 100755 --- a/desks.sh +++ b/desks.sh @@ -6,9 +6,15 @@ # copyleft 2020 Derek Stevens # MIT License - do whatever you want +# if we're feeling spartan, just print a simple string for the executor if [ -z $1 ]; then + echo " >>" + +# if we pass '-x', spit a few hexadecimal bytes into the executor for eye-candy +elif [ "$1" = "-x" ]; then od -vAn -N2 -x < /dev/urandom +# otherwise switch desks else currentDeskNum=$(wmctrl -d | grep -n [*] | awk '{print $1}' | awk -F : '{print $1}') numDesks=$(wmctrl -d | wc -l)