1 2 3 4 5 6 7 8 9
touch .file while set -e ; test -r .file ; do echo -n "stop loop? " read reply case "$reply" in y*) rm .file non-dash-file ;; esac set +e done