rsync, trailing slash, and --delete

Kevin Korb kmk at sanitarium.net
Thu Aug 11 13:14:53 MDT 2011


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

delete will still work.

On 08/11/11 15:06, BJ Quinn wrote:
> I'm trying to rsync a folder like so -
> 
> rsync -aP --delete /home/share_20110801 /lastbackup/share
> 
> Under the /lastbackup folder there is a "share" folder.  I'd like to
> rsync all the contents of the "share _20110801" folder directly under
> the the "share" folder under /lastbackup.  I know I can add the trailing
> slash to the source directory to accomplish this, but then as I
> understand it --delete won't work in that top-level directories deleted
> in the source won't be deleted in the destination.  Is there any way to
> rsync from a folder to a differently named folder without breaking --delete?
> 
> Thanks!
> 
> -BJ Quinn
> 

- -- 
~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~
	Kevin Korb			Phone:    (407) 252-6853
	Systems Administrator		Internet:
	FutureQuest, Inc.		Kevin at FutureQuest.net  (work)
	Orlando, Florida		kmk at sanitarium.net (personal)
	Web page:			http://www.sanitarium.net/
	PGP public key available on web site.
~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (GNU/Linux)

iEYEARECAAYFAk5EKiwACgkQVKC1jlbQAQfYugCeKmQDv/DCVCq/ScGsfQZYqq/L
SqAAmwRq4TvotRI0bP8Dwm6KSfNLtt3Y
=Yv5o
-----END PGP SIGNATURE-----


More information about the rsync mailing list