FTP Library Package 1.2 for Tcl/Tk Manual Pages

COMMAND
FTP::Newer  remote  ?local?
 
The FTP::Newer command has the same behavior as FTP::Get, except that it gets the remote file only if the modification time of the remote file is more recent that the file on the local system. If the file does not exist on the current system, the remote file is considered newer.

If the file was successfully transferred, then the command returns 1, if it fails 0.

EXAMPLE
# package update
if {[FTP::Newer /pub/tcl/httpd/tclhttpd.tar.gz /usr/local/src/tclhttpd.tgz]} {
	exec echo "New httpd arrived!" | mailx -s ANNOUNCE root
}
	

[Contents]  [Previous: FTP::Reget]  [Next: FTP::MkDir]


© 1999 Steffen Traeger