rsync scripting help - changing owner

mbezzo
Contributor III

Hi all,
Trying to get a script put together to move data from one user account to a different one, and critically, update the file owner to the new user. I must be missing something silly, so hoping you all may have been down this road already!

So, I wanna do this:

rsync -rv —chmod=user2+rwX /Users/user1/Desktop/ /Users/user2/Desktop/

What am I doing wrong? Note I want to move the contents of Desktop, and not the whole folder...

Thanks!
Matt

1 REPLY 1

mbezzo
Contributor III

Okay, so you can't use the --chmod= to change the user - this should have been obvious to me (chmod vs chown) lol :)