Two way sync with rsync

后端 未结 10 1684
别那么骄傲
别那么骄傲 2021-01-29 18:50

I have a folder a/ and a remote folder A/. I now run something like this on a Makefile:

get-music:
 rsync -avzru server:/media/10001/music/ /media/Incoming/music         


        
10条回答
  •  清酒与你
    2021-01-29 19:32

    Try Unison: http://www.cis.upenn.edu/~bcpierce/unison/

    Syntax: unison dirA/ dirB/

    Unison asks what to do when files are different, but you can automate the process by using the following which accepts default (nonconflicting) options:

    unison -auto dirA/ dirB/

    unison -batch dirA/ dirB/ asks no questions at all, and writes to output how many files were ignored (because they conflicted).

提交回复
热议问题