I'm getting rather frustrated with an interactive script I'm writing.
The script is divided up, with section for setting variable at the top, then functions (which make up most of the script) then basically a line at the end which calls the first function- the program moves between the functions to do it's thing.
The problem I'm having is when I'm using 'read' to ask the user to 'press return to continue' or suchlike, at some points in the script this works FINE, however at other points it just continues straight through the 'read' without waiting for input or anything. Using 'read -u' had no effect, I have also replaced all these prompts with the following function;
pressreturn() {
echo
echo "Press <RETURN> to continue."
read BLANK
}
This has had no positive effect, the script still ignores the read statement some of the time!
I'm using ksh version M-11/16/88f on AIX 5.2
Thanks for your time on this, folks. I know I havn't provided too much information, I was just hoping this was a not-uncommon gotcha that a few of you might have come up against at one point or another. If anyone requires further information please shout and I'll supply whatever you need.
Regards,
Alex