You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by mi...@apache.org on 2023/10/01 19:11:14 UTC

[maven-reporting-exec] branch MSHARED-1298 created (now 320ea26)

This is an automated email from the ASF dual-hosted git repository.

michaelo pushed a change to branch MSHARED-1298
in repository https://gitbox.apache.org/repos/asf/maven-reporting-exec.git


      at 320ea26  [MSHARED-1298] Missing site report should be detected

This branch includes the following new commits:

     new 320ea26  [MSHARED-1298] Missing site report should be detected

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[maven-reporting-exec] 01/01: [MSHARED-1298] Missing site report should be detected

Posted by mi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

michaelo pushed a commit to branch MSHARED-1298
in repository https://gitbox.apache.org/repos/asf/maven-reporting-exec.git

commit 320ea268d0673bc4d0c5ad44fa67fa8d2cfdfb49
Author: Michael Osipov <mi...@apache.org>
AuthorDate: Sun Oct 1 21:10:18 2023 +0200

    [MSHARED-1298] Missing site report should be detected
    
    This closes #19
---
 .../reporting/exec/DefaultMavenReportExecutor.java    | 19 +++++++------------
 1 file changed, 7 insertions(+), 12 deletions(-)

diff --git a/src/main/java/org/apache/maven/reporting/exec/DefaultMavenReportExecutor.java b/src/main/java/org/apache/maven/reporting/exec/DefaultMavenReportExecutor.java
index ff56597..4c7bfa9 100644
--- a/src/main/java/org/apache/maven/reporting/exec/DefaultMavenReportExecutor.java
+++ b/src/main/java/org/apache/maven/reporting/exec/DefaultMavenReportExecutor.java
@@ -290,14 +290,10 @@ public class DefaultMavenReportExecutor implements MavenReportExecutor {
                 EXCLUDES);
 
         if (!isMavenReport(mojoExecution, pluginDescriptor)) {
-            if (hasUserDefinedReports) {
-                // reports were explicitly written in the POM
-                LOGGER.warn(
-                        "Ignoring {}:{}"
-                                + " goal since it is not a report: should be removed from reporting configuration in POM",
-                        mojoExecution.getPlugin().getId(),
-                        report.getGoal());
-            }
+            // reports were explicitly written in the POM
+            LOGGER.warn("Ignoring {}:{}"
+                            + " goal since it is not a report: should be removed from reporting configuration in POM",
+                    mojoExecution.getPlugin().getId(), report.getGoal());
             return null;
         }
 
@@ -411,15 +407,14 @@ public class DefaultMavenReportExecutor implements MavenReportExecutor {
 
             if (LOGGER.isDebugEnabled()) {
                 if (mojoDescriptor != null && mojoDescriptor.getImplementationClass() != null) {
-                    LOGGER.debug(
-                            "Class {} is MavenReport: ",
+                    LOGGER.debug("Class {} is {}a MavenReport",
                             mojoDescriptor.getImplementationClass().getName(),
-                            isMavenReport);
+                            isMavenReport ? "" : "NOT ");
                 }
 
                 if (!isMavenReport) {
                     LOGGER.debug(
-                            "Skipping non MavenReport {}",
+                            "Skipping non-MavenReport {}",
                             mojoExecution.getMojoDescriptor().getId());
                 }
             }