Re: Script for checking WinSCP Sync or Not
Yes, that's correct.
ERRORLEVEL
to 1
then?
2batch2
winscp /ini=nul /script="C:\scripts\sync.script"
open sftp://<site> -hostkey="<key info>"
synchronize local -resumesupport=on -filemask=file.zip c:\scripts\ /
close
bye
Searching for host...
Connecting to host...
Authenticating...
Using username "<user>".
Authenticating with pre-entered password.
Authenticated.
Starting the session...
Session started.
Active session: [1] <site>
Comparing...
Local 'c:\scripts\OlderFiles' <= Remote '/OlderFiles'
Nothing to synchronize.
Session '<site>' closed.
No session.
IF
statement against it to determine to copy the file/send email/etc.. or do nothing. Help appreciated in advance. Thanks. :)