Date: 2003-12-01 06:25:58 PST
newexpextuser asked
"What I don't understand is with the above "ftp rename \m(nameonly)
.../ready/\m(nameonly)", how does this avoid moving the partial file
from the working directory to the ready directory, there will still be
a file in the working directory albeit a partial file and this command
will move it along to the ready directory."

Date: 2003-12-01 08:43:26 PST
Frank answers
"The lines preceding the "ftp rename" command are:

ftp put /delete \m(filename)
if fail exit 1 ftp put \m(filename): \v(ftp_message)

Thus the "ftp rename" command won't be reached if "ftp put" fails.
This is exactly the reason that we recommend that each critical step
be checked with IF FAIL -- you don't want the script to proceed in
cases where the subsequent commands require the preceding ones to

Of course conditional command in the IF statement need not be EXIT; it
can be anything you want, even a series of commands, e.g.:

if fail {
} else { ; The ELSE part is optional

- Frank"

Date: 2003-12-01 09:52:52 PST
newexpextuser asked
"I appreciate your input.

However, I have gone through several articles on the website,
searching through the newsgroups and reviewing case studies and have
not found anything that addresses the issue I am having.

If there is online training or even classroom training, I'd find this
as being beneficial.

The case study I was pointed to, mentioned ftping a file to a central
server in a "working" directory where another script running on the
central server would look for files in a "ready" directory. I can
understand this concept, as it is obvious you wouldn't want to process
a file that is still being in transit.

It goes on to suggest of having the script move the file from the
working directory to the ready directory, but what if there is a
partial file there, it would still try to move this partial file and
try to process it."

Now my post:
We would be pleased to provide custom classroom training on Kermit scripting