Rsync is just great to synchronize files between two locations, wether they are two directories on your local hard drive or two shares located on servers thousands of kilometers apart. In addition, with --include
and --exclude
patterns, you can get rsync to transfer just the files you want.
rsync -avz --include "*_small.jpg" --exclude "*.jpg" dir1/ dir2/
will not transfer JPEG files between dir1 and dir2 (and their sub-directories) unless their name ends with _small.jpg
. This way you can transfer only the reduced version of your pictures to you website for example.
Continue reading ‘rsync only files matching pattern,
a Subversion application’
Recent Comments
a Subversion application
a Subversion application
a Subversion application