SNAPSHOT Take a “snapshot” of the local PC file system |
Top Previous Next |
This script command is used in conjunction with the DIFF and GETDIFF script commands to locate individual file differences (i.e., change in size, date/time stamp) within the current working folder (and optional subfolder tree) of the local PC file system.
SNAPSHOT is the first step to establish a baseline (or “snapshot”) you can later use to determine if any files changed. Details about files in the current directory that match the [ filename ] argument are saved in an SQL database file. The database file name defaults to “snapshot_local.sql” but you may name it anything you like via the [ dbfile ] argument.
As long as unique and consistent [ dbfile ] arguments are specified, Robo-FTP supports as many separate snapshots as you wish.
Consider the following example which takes a snapshot of all files in the current working folder and any subfolders.
SNAPSHOT "*" /incldirs
In most cases SNAPSHOT need only be run once. Future changes detected by the DIFF command are automatically updated in the database by default.
The total number of files examined in the local PC file system is saved in the %snapshotfiles script variable.
The internal variable %currentlocaldir contains the name of the current working directory and the WORKINGDIR command may be used to change the current working directory.
The FTPSNAPSHOT command provides similar functionality for remote servers.
Related Command(s): DIFF, GETDIFF, DIFFREWIND See Also: FTPSNAPSHOT
|