$ cursor 12 40
Now imagine that the cursor is sitting in the middle of the screen. cursor is quite fast, but there is a much faster way. Set a shell variable like L22 to move to the 22nd line like this:
$ L22=`cursor 23 0`
Then,
$ echo "$L22$MESSAGE\ec"
The double quotes surround the messages in case they contain special characters. The \ec tells echo not to print a carriage return. Some versions of UNIX use the -n switch instead of \ec:
$ echo -n "$L22$MESSAGE"
(The prompt command, which figures out which flavor of newline suppression your echo command uses, can be substituted for echo.) SEE ALSO