Linux – diff folders and copy results over

centoscopydiff()fileslinux

We use a third party newsletter system which updates frequently, usually around 100 files. Each time all the developers release is the whole application again with a changelog but there's usually too many files listed for it to be useful. The system – once online – generates a lot of files (caches etc) so i dont want to download the remote files to do a local diff each time either. What i want to do is upload the zip of all the newly released files and run a Diff (or similar) and copy over from new_files -> existing_files just the updated files and ignore the files in existing that aren't in new. Whats the best way to do this?

I know this can be achieved to an extent using copy but its my understanding that this is largely based on last edited date but i'm more interested in actual file differences

This is on CentOS 5 and i have shell access

Thanks.

Best Answer

With linux, ssh in and use rsync

this will help

http://troy.jdmz.net/rsync/index.html