ignore unknown arguments that don't start with a "-"

This commit is contained in:
Jérémy Lecour 2019-03-13 16:50:26 +01:00 committed by Jérémy Lecour
parent c9c061f811
commit b8b94a66ce

View file

@ -333,13 +333,14 @@ while :; do
shift
break
;;
-?*)
-?*|[[:alnum:]]*)
# ignore unknown options
printf 'WARN: Unknown option (ignored): %s\n' "$1" >&2
;;
*)
# Default case: If no more options then break out of the loop.
break
;;
esac
shift