commit 61a6dfbb5653a440e9a76183d34f059e065baf95
parent 5cebc5a55305db76a39653bd446f2972b401f63c
Author: Anders Damsgaard <andersd@riseup.net>
Date: Tue, 16 Jan 2018 12:50:04 -0800
Add further flags related to looping
Diffstat:
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/granular-status.sh b/granular-status.sh
@@ -4,16 +4,20 @@
# simulations. You may want to add this to your shell's PATH variable.
set -e
-cmd_sing='julia --color=yes -e "import Granular; Granular.status()"'
+cmd_single='julia --color=yes -e "import Granular; Granular.status()"'
cmd_loop='julia --color=yes -e "import Granular; Granular.status(loop=true, t_int=10)"'
cmd_render='julia --color=yes -e "import Granular; Granular.status(visualize=true)"'
if [[ "$1" == "loop" ]]; then
eval $cmd_loop
+elif [[ "$1" == "-l" ]]; then
+ eval $cmd_loop
+elif [[ "$1" == "--loop" ]]; then
+ eval $cmd_loop
elif [[ "$1" == "render" ]]; then
eval $cmd_render
elif [[ "$1" == "visualize" ]]; then
eval $cmd_render
else
- eval $cmd_sing
+ eval $cmd_single
fi