summary refs log tree commit diff
path: root/bin/cash/tests/builtins/getopts9.0
blob: 3f96c4dac10e776d3ec3ac25e920af1773a72dde (plain) (blame)
1
2
3
4
5
6
7
8
9
# $FreeBSD: releng/12.0/bin/sh/tests/builtins/getopts9.0 297752 2016-04-09 16:06:13Z jilles $

args='-ab'
getopts ab opt $args
printf '%s\n' "$?:$opt:$OPTARG"
for dummy in dummy1 dummy2; do
	getopts ab opt $args
	printf '%s\n' "$?:$opt:$OPTARG"
done