diff --git a/.local/bin/tools/timer b/.local/bin/tools/timer index 24b0e16..a37c049 100755 --- a/.local/bin/tools/timer +++ b/.local/bin/tools/timer @@ -36,10 +36,17 @@ stopwatch() { done } +no_args="true" while getopts "c:sh" arg; do case $arg in c) countdown $OPTARG;; s) stopwatch;; h) echo "$help";; + *) echo "$help";; esac + no_args="false" done + +if [ "$no_args" = "true" ]; then + echo "$help" +fi