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

The way I think of it is that by default everything is included.
Excludes override that and remove certain paaterns.  Includes override
that and put back in certain patterns.

On 07/03/13 05:55, Grant wrote:
>>>> Anyways, the other way to do what you are asking is: rsync
>>>> -azvi --exclude-from=excludes.txt --delete --delete-excluded
>>>> / user@hostname:
>>>> 
>>>> excludes.txt: + / + /etc + /etc/** + /home + /home/*/ + 
>>>> /home/*/.maildir/ + /home/*/.maildir/** - - *
>>> 
>>> So the includes are in excludes.txt prefixed with "+ " and the 
>>> excludes are prefixed with "- - "?
>> 
>> I am not sure where the second - came from.  That line should
>> have been "- *" as in exclude everything that I didn't explicitly
>> include previously (order matters).  I find it much easier to
>> list both in a single file rather than using two since order is
>> so important.
> 
> Is there a rule I can apply to figure out the proper order for 
> includes and excludes?  I found that:
> 
> - /folder1/folder2
> 
> needs to be above:
> 
> + /folder1/**
> 
> but  "- *" needs to be at the very end which is confusing.
> 
> - Grant
> 

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

iEYEARECAAYFAlHUYc8ACgkQVKC1jlbQAQdtlwCdFwsHu1/ylUgt0y7yHYT7E2DB
B+sAnRSA3fTCy5ATpSJm9spVe9d9sxds
=dttX
-----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 via email to