Re: ksh-Script

Robert Grill <[email protected]>
Newsgroups gmane.linux.redhat.general.german
Message-ID <1099304542.1245.33.camel@papa-neu>
Hallo Richard,

ich habe hier keine Korn-Shell
aber ein symbolic link auf die bash tut es bei mir auch :-)

>Weiss jemand wie man das Unterbinden kann (eventuell mit "trap",...) ?

Wie wäre es mit case?

#!/bin/ksh
echo "\tDo you want to continue ? <y/n> \c"
read answer

case "$answer" in
        n)
                echo "exiting......"
                echo "... type ENTER ..."
                read a
                exit 1
        ;;

        y)
                echo
                echo "Going on ..."
                echo
        ;;
        *)
                echo "Usage: $0 {y|n}"
                exit 1
esac


schönen Tag noch

Robert
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.