I personally feel uncomfortable with unbalanced if-else conditions like `if (a && b) else if (a)`. I'd prefer this block to be:

    if (r == pubspecFile) {
      if (delta.isDelete) {
        analyzePubspec = false;
        break;
      } else {
        analyzePubspec = true;
      }
    } else if (properties.isInPackagesFolder(r)) {
      analyzePubspec = true;
    }