We need to calculate size so we get an idea of actual used disk space
(which is closer to how much maximum space will be used in the backup,
in case files have huge holes). Calculate it once to avoid errors.
By ensuring that directory names end in '/', the behavior of
"match only directories if the pattern ends with /" comes for
free based on how wcmatch.glob works, so we don't need to run
the regex match twice.