Either format is correct. However, there is no quoting or escaping in
the file. So:
- filename1
- file name 1
or without the -
On 1/3/20 1:45 PM, @lbutlr via rsync wrote:> I have seen two main styles in examples for using rsync with exclude-from.
>
> The first is simply a list of filename, one per line.
>
> The second is a list of filenames, one per line, prefixed with either a -
or a + to indicate exclude/include. Which is correct?
>
> Also, none show the correct style with a filname containing spaces, though
I assumed quoting is OK
>
> Exclude1.txt:
> - filename1
> - ?file name 1?
>
> Exclude.txt:
> filename1
> ?file name 1?
>
> Which of these will exclude both filename1 and ?file name 1? anywhere they
appear in the source?
>
>
--
~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,
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: https://sanitarium.net/
PGP public key available on web site.
~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: OpenPGP digital signature
URL:
<http://lists.samba.org/pipermail/rsync/attachments/20200103/1b187db4/signature.sig>