fixes #3: support wildcard; fix an unexpected exit; standardize exit code