Add a --count flag that prints how many checks ran #31

Open
kami wants to merge 4 commits from orchestra/06G4WJ9T4F35NZC4Z8QQXM9Z6G into master
Showing only changes of commit 01f7418f18 - Show all commits
+4
View File
@@ -13,6 +13,7 @@ shebang_is_bash usage_text_mentions_every_flag"
# name=ok / name=fail pairs, in run order.
RESULTS=
FAILED=0
# TOTAL is the number of checks that ran, reported by --count.
TOTAL=0
# record <name> <status>: append one outcome to the results state.
@@ -102,6 +103,7 @@ main() {
local summary=
local timing=
local strict=
local count=
local unknown=
for arg in "$@"; do
if [ "$arg" = --help ]; then
@@ -123,6 +125,8 @@ main() {
timing=1
elif [ "$arg" = --strict ]; then
strict=1
elif [ "$arg" = --count ]; then
count=1
else
[ -n "$unknown" ] || unknown=$arg
fi