move all arguments of rsync command into a separate function