in/exclude[=] and multiple sources
Steven Levine
steve53 at earthlink.net
Fri Aug 19 11:35:24 MDT 2011
In <CE4BCF0B-F15A-4665-A5A7-DE3C51183A00 at ukgb.net>, on 08/19/11
at 11:49 AM, Ken Gillett <emailist at ukgb.net> said:
Hi Ken,
>I still think the docs should explain you can use either form.
It does. The first paragraph of the OPTIONS section states
<snip>
rsync uses the GNU long options package. Many of the com-
mand line options have two variants, one short and one
long. These are shown below, separated by commas. Some
options only have a long variant. The = for options that
take a parameter is optional; whitespace can be used
instead.
</snip>
>Are there ANY situations when either form will NOT work?
Baring defects, no.
>So one can think of rsync working on each source in turn and applying all
>the include and exclude options to each source directory as it works on
>that source. That's what I already surmised so thanks for the
>confirmation.
As stated in the second paragraph of the FILTER RULES section
<snip>
As the list of files/directories to transfer is built,
rsync checks each name to be transferred against the list
of include/exclude patterns in turn, and the first match-
ing pattern is acted on: if it is an exclude pattern,
then that file is skipped; if it is an include pattern
then that filename is not skipped; if no matching pattern
is found, then the filename is not skipped.
</snip>
Mentally, I replace references to file and filename to file/directory,
because that's really what is meant.
The man page contains a lot of information, so it's easy enough to miss
stuff even when one is looking for it specifically.
Steven
--
----------------------------------------------------------------------
"Steven Levine" <steve53 at earthlink.net> eCS/Warp/DIY etc.
www.scoug.com www.ecomstation.com
----------------------------------------------------------------------
More information about the rsync
mailing list