#compdef -command- local nm=$compstate[nmatches] ret=1 compgen -c && ret=0 if [[ nm -eq compstate[nmatches] ]]; then _path_files -/g "*(*)" else return ret fi