xref: /freebsd/bin/sh/tests/builtins/getopts9.0 (revision 5ca8e32633c4ffbbcd6762e5888b6a4ba0708c6c)
1
2args='-ab'
3getopts ab opt $args
4printf '%s\n' "$?:$opt:$OPTARG"
5for dummy in dummy1 dummy2; do
6	getopts ab opt $args
7	printf '%s\n' "$?:$opt:$OPTARG"
8done
9