From a91ff5e1bd4b48a6dddae445bbf1956ffaea6736 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Mon, 16 Oct 2017 23:50:40 -0400 Subject: [PATCH] imgcrush: parse multiple arguments correctly --- .bin/imgcrush | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.bin/imgcrush b/.bin/imgcrush index 3f04460..51ba343 100755 --- a/.bin/imgcrush +++ b/.bin/imgcrush @@ -21,6 +21,7 @@ crush() { case $1 in *.jpg|*.jpeg) crush_jpg "$1" ;; *.png) crush_png "$1" ;; + *) echo "${0##*/}: unsupported format: $1" >&2 ;; esac } @@ -31,7 +32,7 @@ main() { case $1 in -h) usage ;; -*) usage 1 ;; - *) crush "$1" ;; + *) crush "$1"; shift ;; esac done } -- 2.39.5