I thought that this would delete backblaze:\A and backblaze:\B, because it would sync Y: -> backblaze: while including only the listed paths. It did not do that, which is great and just what I need. So I gather that the --include flag calculates the sync operations separately per included path, rather than the whole source path, with --include acting as a simple filter.
I just want to make sure that I have understood this all correctly, and that this is the intended behavior, so that I can expect to accomplish what I want by running those two commands.
Rclone won't delete stuff that is excluded from the sync. So if you've got --include A/** it won't delete anything outside of A. (Unless you include the --delete-excluded flag of course!)
The reason this works is that you've written --include /* which can only match files in the root. If you'd have written --include /** then it would have removed A and B.
Yes it looks good If you ever create a file called A or B in the root of Y: then there will be trouble though.
To work around this you'd exclude A and B from that sync. You need to use --filter for this as you can't mix --include and --exclude on one line. So something like
Unions look interesting. Hadn't seen those. Consolidating into a single command would be great, but I have some conflicting symlinks, such as X:\C -> Y:\C. I understand these are resolved using policies, but I'm not entirely sure what would happen in this case. I suspect only the symlink would be synced. Is it dependent on your symlink parameters? I need to sync while preserving symlinks deeper in the directories.