in src/main/java/org/apache/sling/feature/cpconverter/vltpkg/WorkspaceFilterBuilder.java [160:182]
private static PathFilterSet copyPathFilterSet(@NotNull PathFilterSet pfs, @NotNull Set<String> filteredPaths) throws ConfigurationException {
// create a new path-filter-set
PathFilterSet filterSet = new PathFilterSet(pfs.getRoot());
filterSet.setType(pfs.getType());
filterSet.setImportMode(pfs.getImportMode());
// copy all entries to the new path-filter-set
for (FilterSet.Entry<PathFilter> entry : pfs.getEntries()) {
if (entry.isInclude()) {
filterSet.addInclude(entry.getFilter());
} else {
filterSet.addExclude(entry.getFilter());
}
}
// for all paths that got filtered out and moved to repo-init make sure they get explicitly excluded
for (String path : filteredPaths) {
if (pfs.covers(path)) {
filterSet.addExclude(new DefaultPathFilter(path));
}
}
return filterSet;
}