rsync.py: a sort of rsync algo