Darren
Darren

Reputation: 11031

How to have rSync only transfer final folder?

Hey all, I don't know how to properly phrase this but when I run (ignore $DESTINATION):

rsync -avz tmp $DESTINATION

it will transfer the full path of tmp. So save if tmp is in /root/tmp instead of putting just tmp in my destination folder it puts the full path of /root/tmp or wherever it is located... is there a way around this? I just want to put the specific directory and everything in it... not the path above it as well.

Thanks

Upvotes: 0

Views: 72

Answers (1)

Liv
Liv

Reputation: 6124

use -R to use relative file names.

Upvotes: 1

Related Questions