FTPDIFF Look for differences in the remote site file system |
Top Previous Next |
This script command is used in conjunction with the FTPSNAPSHOT and FTPGETDIFF script commands to locate individual file differences (i.e., change in size, date/time stamp) within a specified folder (and optional subfolder) tree within the remote site file system.
FTPSNAPSHOT is the first step to establish a baseline (or “snapshot”) of the specified folder(s) from which to determine if any file(s) change and FTPDIFF is used subsequently to compare the current state of the file system with what was saved in [ dbfile ]. Any changes found are saved back into the same database file (to be processed using the FTPGETDIFF command) and the original snapshot is updated to reflect the current state of the file system (unless this is suppressed by the inclusion of the /noupdate option.
If the [ dbfile ] argument is specified it must be the name of a database file previously created by the SNAPSHOT command. If omitted the default “snapshot_site.sql” file is used.
Consider the following example which compares the current working folder and any subfolders with the snapshot saved in the default “snapshot_site.sql” file.
FTPDIFF "*" /incldirs
The total number of differences found in the remote site file system is saved in the %ftpdifffiles script variable.
Important The success of this command depends on Robo-FTP's ability to automatically read and understand the directory listings returned by the remote site. It is not uncommon for HTTP/HTTPS sites to fail to return any directory listings or to return listings in an unsupported format. Contact technical support if you have an urgent need related to a directory listing format that is currently unsupported.
Important If the “snapshot_site.sql” database file does not exist, and there is no alternate database file specified, the FTPDIFF command creates an empty FTPSNAPSHOT database so all files will appear to be "new" if you subsequently process the differences in a FTPGETDIFF loop.
Related Command(s): FTPGETDIFF, FTPDIFFREWIND, FTPSNAPSHOT See Also: DIFF |