compare 2 directories and copy differences in a 3rd directory

Published: 5/10/2017
compare 2 directories and copy differences in a 3rd directory
Source: SERVERFAULT.COM

Running ubuntu 12.04, I want to compare 2 directories, say folder1/ and folder2/ and copy any files that are different to folder3/. There are also nested files, so matching subdirectories should be copied as well Is there a single command that would help me? I can get the full list of changed files running: rsync -rcnC --out-format="%f" folder1/ folder2/ But rsync doesn't seem to have the abili

Read more
Related news
Comment