Discussion Locked
0 helpful
1 reply
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I have an ftp batch script that I am using within a bat file. Is there anyway to capture/query the results of the ftp script. For instance, I would like to be able to tell if ftp error code 552 resulted during a file upload. I am capturing the ftp output but don't know how to utilize within my bat file. For instance, can I somehow use the 'find' command to do this?
1 reply
by danlm
would actualy to code for errors within your script. here is how I did it in a shell script for a unix box
[i]ftp -i -v -n ftp.droolin.org < $HOME/Unreal3.2/config/damnit.txt[/i]
That was the ftp to a home server with all display output being directed to damnit.txt
Here is the check against that file for an error.
[i]grep '530 Login incorrect.' $HOME/Unreal3.2/config/damnit.txt > $HOME/Unreal3.2/config/damnit1.txt
if test -s $HOME/Unreal3.2/config/damnit1.txt
then
notify_email "Subject: Incorrect password was specified for $SERVERNAME. FTP update has aborted"
fi[/i]
Dan
This discussion is closed to new replies.
Trending Web Development posts
Sort by Trending
1 helpful
10 replies
1 helpful
3 replies
Question
Windows and macOS computers becoming slow or unstable after updates - what should I check first
0 helpful
1 reply
Discussion
Optimizing WordPress widgets and DOM size
0 helpful
3 replies
Discussion Locked
Best Ways to Improve Website Visibility
0 helpful
5 replies