items and/or ignore +/- prefixes.
- add_exclude_file() changed to take the same flags as add_exclude().
- add_exclude_line() was removed since add_exclude() can now do its job.
- make_exclude() now takes a size-limited string without a +/- prefix.
- add_cvs_excludes() was changed to word-split the items that come from
a .cvsignore file, and to ignore all +/- prefixes in all the ignore
sources. Since CVS doesn't check if its ignore items are directories,
the dir-names (e.g. SCCS, CVS, etc.) no longer have a trailing slash
(making our excludes match CVS's ignores more exactly).
an extra "- " or "+ " parsed off the start of the name (i.e. we have to
quote excluded names that start with those strings with an extra "- "
at the start).
path (clear to the root). Changed several functions to make the args
more general (to support separated lists), more consistent, and easier
to understand.
The --cvs-exclude option is broken in the CVS version of rsync
because of a cut-and-paste-induced bug in exclude.c:
This bug could cause the sending rsync to crash when it dereferenced
a NULL pointer.
slashes. The old behavior of crossing slashes can be achieved by using a
double-asterisk ('**') anywhere in a pattern. Note that this can change
some existing exclude patterns in a subtle way. Also note that if the
remote side is an older release the processing on the two sides might not
be exactly the same when there's no double-asterisk, which can affect which
files are excluded from deletion, but they're close enough that people will
probably not notice. I considered changing the protocol version and
checking the remote_version number to ensure the same processing on both
sides, but the exclude patterns are pre-processed before the remote version
number is known and it's just not worth going through extraordinary efforts.
Suggested by Cameron Simpson <cs@zip.com.au>
of non-wildcard includes followed by an exclude of *) so that it will silently
ignore included files that don't exist rather than saying "No such file or
directory". This is more like the behavior of the non-optimized include mode.
probably cause any harm if they were treated as normal exclude or include
patterns because they just wouldn't match anything, but it's better to
explicitly ignore them. Suggested by David Holland <uholld1@lexis-nexis.com>
when people do --exclude "*". Also, add an example to the man page that
shows explicitly including parent directories when itemizing specific
paths to include followed by --exclude "*".
that indicate a feature is not supported. Two places that are normally
ifdefed out used RERR_UNSUPPORTED whereas one other place and errcode.h
used RERR_NOSUPPORT. Changed them all to consistently use RERR_UNSUPPORTED.
The two things that had the bad values were #ifndef SUPPORT_LINKS and
#ifdef NO_INT64. The former is probably for non-Unix operating systems
and the latter was at least on the default Unixware compiler.
could only include files before if "+ " was explicitly prefixed on files
from any exclude or include option. Also simplified the code by removing
the "orig" exclude_struct element, and reduced the number of bytes
transferred from client to server by never including "- " prefixes in the
transmitted exclude list because exclusion is the default.