if test ! -d "$1"; then echo "$progname: $1: not a directory, skipping." >&2 + shift continue fi Thanks, updated.