From 6b2494424fc8e6c49d6816294b5df5b1fe7f4c74 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Mon, 17 Dec 2018 17:11:30 -0500 Subject: tests.sh: Add a --help with usage information --- tests.sh | 37 ++++++++++++++++++++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/tests.sh b/tests.sh index 35f0224..4afe094 100755 --- a/tests.sh +++ b/tests.sh @@ -606,6 +606,36 @@ bfs_tests=( test_deep_strict ) +function usage() { + local pad=$(printf "%*s" ${#0} "") + cat <&2 + printf "Unrecognized option '%s'.\n\n" "$arg" >&2 + usage >&2 exit 1 ;; esac -- cgit v1.2.3