elharo commented on code in PR #712:
URL:
https://github.com/apache/maven-checkstyle-plugin/pull/712#discussion_r4657982772
##########
src/main/java/org/apache/maven/plugins/checkstyle/CheckstyleViolationCheckMojo.java:
##########
@@ -882,6 +892,63 @@ private List<File> getTestSourceDirectories() {
return testSourceDirs;
}
+ private boolean hasFilesToProcess() throws MojoExecutionException {
+ try {
+ if (hasFiles(getSourceDirectories())) {
+ return true;
+ }
+ if (includeTestSourceDirectory &&
hasFiles(getTestSourceDirectories())) {
+ return true;
+ }
+ return (includeResources && hasResourceFiles(resources))
+ || (includeTestResources &&
hasResourceFiles(testResources));
+ } catch (IOException e) {
+ throw new MojoExecutionException("Failed to determine files to
process", e);
Review Comment:
I'm tempted to just default to true here
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]