ottlinger commented on code in PR #240:
URL: https://github.com/apache/creadur-rat/pull/240#discussion_r1581906050


##########
apache-rat-core/src/main/java/org/apache/rat/Defaults.java:
##########
@@ -57,6 +62,10 @@ public class Defaults {
     public static final String UNAPPROVED_LICENSES_STYLESHEET = 
"org/apache/rat/unapproved-licenses.xsl";
 
     private final LicenseSetFactory setFactory;
+
+    private final FilenameFilter filesToIgnore = 
WildcardFileFilter.builder().setWildcards("*.json").setIoCase(IOCase.INSENSITIVE).get();
+
+    private final IOFileFilter directoriesToIgnore = 
NameBasedHiddenFileFilter.HIDDEN;

Review Comment:
   Should we create a new class for these 2 members? ScanDefaults that contains 
files and directories to ignore?
   
   ScanDefault {
   List<String> filesToIgnore; // wildcards
   List<IOFileFilter> directoriesToIgnore; // not sure if IOFileFilter is the 
correct superclass
   }
   
   WDYT?
   
   This would allow to have a static version of this configuration set in 
Defaults.java such as
   
   public static ScanDefault RAT_DEFAULT_SCAN = new 
ScanDefault(List.of(*.json),List.of(NamebasedHiffenFilterFilter.HIDDEN); 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@creadur.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to