public override bool Accept(IActivityMonitor m, ModifiedDiff modifiedDiff) { var matchingPath = DiffRoot.Paths.FirstOrDefault(path => modifiedDiff.OldPath.StartsWith(path) || modifiedDiff.NewPath.StartsWith(path)); if (matchingPath != null) { m.Debug($"Modified file ('{modifiedDiff.OldPath}'=>'{modifiedDiff.NewPath}') matched with one of the DiffRoot '{DiffRoot.Name}' path: {matchingPath}"); ModifiedDiffs.Add(modifiedDiff); return(true); } m.Debug($"Modified file ('{modifiedDiff.OldPath}'=>'{modifiedDiff.NewPath}') did not match with any of the DiffRoot '{DiffRoot.Name}' paths."); return(false); }
public override bool Accept(IActivityMonitor m, ModifiedDiff modifiedDiff) { ModifiedDiffs.Add(modifiedDiff); return(true); }