So I am trying to use --filter with a StringArray of rules. How do I define more than one rule? Do I need to repeat --filter for each one or can I list all the paths inside a bash array somehow E.g. a command line:
P.S. When I do this it works, but it's not a StringArray the way I understand it. rclone copy --dry-run -v --filter "+ /home/user1/Documents/Stocks/**", --filter "- *" /home/user1/Documents/ coder:/backups/lggram
PPS: I do use --filter-from succesfully. I just want to know how to use from command line correectly
I understand there can be some confusion, and there are several other variants of multi-value options which may also add to the confusion. The terms used for the option value types in documentation are basically the type names as they are written in the source code.
We have tried to explain a bit in documentation, and the answer to your question is there:
Options documented to take a stringArray parameter accept multiple values. To pass more than one value, repeat the option; for example: --include value1 --include value2 . Other options may only accept a single value, and should only be specified once, but where the specified parameter may indicate a list of values separated by space or comma. Such options are documented to take a CommaSepList parameter, if comma separated, and SpaceSepList if space separated, although some may also have different parameters such as DumpFlags or just string and the help text explains that this will be interpreted as a list.
Thanks for the explanation. I was looking for an example in the filters docs. But would be helpful to have a note/link pointing to the definition of stringArray for us coders.