1 2 3 4 5 6 7 8 9 10 11
#!/bin/sh echon "$1 (y/n) [$2] ? " X="" read X if [ "$X" = "" ]; then X="$2" fi case "$X" in [yY]*) exit 0;; *) exit 1;; esac