Hi Admins,
I have the following script which is executed from a ksh clients .profile:
(grep exec .profile = "exec the_below_script")
#!/bin/sh
stty intr '^-'
echo " **************************
echo " * A) Run program A *
echo " * B) Run Program B *
echo " **************************
echo " * 9) Exit
END1=0
while test $END1 = 0
do
END1=1
echo "Please Enter Choice: \c"
read INPUT1
case $INPUT1 in
a|A) /apps/scripts/programA
b|B) /apps/scripts/programB
9|EXIT|exit|E|e|Q|q) END1=1;;
*) END1=0;;
esac
done
stty intr '^c'
exit 0
I would like to add the F4 function key entry to the exit condition:
9|EXIT|exit|E|e|Q|q) END1=1;;
When in the while statement, hitting function key F4 returns to the screen
"^[OS", example:
Please Enter Choice: ^[OS
Is there a way to capture the F4 function key to exit the shell?
Best Regards,
Blake Brehl
Sys Admin/DBA
Anritsu Company United States
Morgan Hill, CA
Received on Fri May 28 2004 - 21:46:24 NZST