Does the --delete conflict with --files-from?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Does the --delete conflict with --files-from?

Hongyi Zhao
Hi all,

I've tried to use the --files-from and  --delete options together.

But finally find that in this case, the `--delete' won't delete the
extraneous files from dest dirs.

So, does the  --delete conflict with --files-from?

Any hints on this issue?

Regards
--
.: Hongyi Zhao [ hongyi.zhao AT gmail.com ] Free as in Freedom :.

--
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
Reply | Threaded
Open this post in threaded view
|

Re: Does the --delete conflict with --files-from?

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

Technically no, practically kinda...
Deleting files only works when you are syncing a directory.  If you
specify every file to copy then you aren't actually syncing anything
and there is nothing for --delete to do.  So, --delete will only work
if your files-from file is a list of directories rather that files.

OTOH, you are probably actually looking for the --delete-missing-args
option which is a fairly new feature.

On 04/15/2015 02:29 AM, Hongyi Zhao wrote:

> Hi all,
>
> I've tried to use the --files-from and  --delete options together.
>
> But finally find that in this case, the `--delete' won't delete the
>  extraneous files from dest dirs.
>
> So, does the  --delete conflict with --files-from?
>
> Any hints on this issue?
>
> Regards
>

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

iEYEARECAAYFAlUuCa0ACgkQVKC1jlbQAQeFngCfakB7dLe5Vq9EM+4qOLIbiOls
bjcAmgK28diby6tn6dOOGrFQ6NscrKMa
=PiO6
-----END PGP SIGNATURE-----
--
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
Reply | Threaded
Open this post in threaded view
|

Re: Does the --delete conflict with --files-from?

Hongyi Zhao
On Wed, 15 Apr 2015 02:48:13 -0400, Kevin Korb wrote:

> Technically no, practically kinda...
> Deleting files only works when you are syncing a directory.  If you
> specify every file to copy then you aren't actually syncing anything and
> there is nothing for --delete to do.  So, --delete will only work if
> your files-from file is a list of directories rather that files.
>
> OTOH, you are probably actually looking for the --delete-missing-args
> option which is a fairly new feature.

Thanks a lot for your hints.

Regards
--
.: Hongyi Zhao [ hongyi.zhao AT gmail.com ] Free as in Freedom :.

--
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html