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 2022/05/18 08:15:09 UTC

[maven-site-plugin] branch MSITE-901 updated (7988b100 -> 4a38a81f)

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

michaelo pushed a change to branch MSITE-901
in repository https://gitbox.apache.org/repos/asf/maven-site-plugin.git


    omit 7988b100 [MSITE-901] If precending standalone report has been run, site:jar does not reinvoke site:site
     add 65a80522 [MSITE-902] Upgrade Plexus Utils to 3.4.2
     new 4a38a81f [MSITE-901] If preceding standalone report has been run, site:jar does not reinvoke site:site

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (7988b100)
            \
             N -- N -- N   refs/heads/MSITE-901 (4a38a81f)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

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.


Summary of changes:
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


[maven-site-plugin] 01/01: [MSITE-901] If preceding standalone report has been run, site:jar does not reinvoke site:site

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

michaelo pushed a commit to branch MSITE-901
in repository https://gitbox.apache.org/repos/asf/maven-site-plugin.git

commit 4a38a81f06d5ba95eb9d8d1ebb89b4f88c4932c3
Author: Matt Nelson <ma...@cerner.com>
AuthorDate: Fri Mar 20 18:05:04 2020 -0500

    [MSITE-901] If preceding standalone report has been run, site:jar does not reinvoke site:site
    
    This closes #82
---
 src/it/projects/MSITE-901/invoker.properties       | 18 +++++
 src/it/projects/MSITE-901/pom.xml                  | 78 ++++++++++++++++++++++
 src/it/projects/MSITE-901/verify.groovy            | 27 ++++++++
 .../maven/plugins/site/render/SiteJarMojo.java     |  7 +-
 4 files changed, 125 insertions(+), 5 deletions(-)

diff --git a/src/it/projects/MSITE-901/invoker.properties b/src/it/projects/MSITE-901/invoker.properties
new file mode 100644
index 00000000..a644cb7e
--- /dev/null
+++ b/src/it/projects/MSITE-901/invoker.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+invoker.goals = clean package
diff --git a/src/it/projects/MSITE-901/pom.xml b/src/it/projects/MSITE-901/pom.xml
new file mode 100644
index 00000000..a89260c7
--- /dev/null
+++ b/src/it/projects/MSITE-901/pom.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.plugins.site.it</groupId>
+  <artifactId>MSITE-901</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+
+  <description>Verifies that the site:jar goal output is not altered by the pmd/cpd skipEmptyReport property</description>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-pmd-plugin</artifactId>
+        <version>3.16.0</version>
+        <executions>
+          <execution>
+            <goals>
+              <goal>check</goal>
+            </goals>
+            <phase>process-sources</phase>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-site-plugin</artifactId>
+        <version>@project.version@</version>
+        <executions>
+          <execution>
+            <goals>
+              <goal>jar</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+
+  <reporting>
+    <plugins>
+      <plugin>
+        <artifactId>maven-project-info-reports-plugin</artifactId>
+        <version>@projectInfoReportsPluginVersion@</version>
+        <reportSets>
+          <reportSet>
+            <reports>
+              <report>index</report>
+            </reports>
+          </reportSet>
+        </reportSets>
+      </plugin>
+    </plugins>
+  </reporting>
+
+</project>
diff --git a/src/it/projects/MSITE-901/verify.groovy b/src/it/projects/MSITE-901/verify.groovy
new file mode 100644
index 00000000..1cf15bed
--- /dev/null
+++ b/src/it/projects/MSITE-901/verify.groovy
@@ -0,0 +1,27 @@
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+File buildLog = new File( basedir, 'build.log' )
+assert buildLog.exists()
+
+File siteIndex = new File( basedir, 'target/site/index.html' )
+File sitePmd = new File( basedir, 'target/site/pmd.html' )
+assert siteIndex.exists()
+assert sitePmd.exists()
diff --git a/src/main/java/org/apache/maven/plugins/site/render/SiteJarMojo.java b/src/main/java/org/apache/maven/plugins/site/render/SiteJarMojo.java
index 26be6d40..8471aed9 100644
--- a/src/main/java/org/apache/maven/plugins/site/render/SiteJarMojo.java
+++ b/src/main/java/org/apache/maven/plugins/site/render/SiteJarMojo.java
@@ -45,7 +45,7 @@ import org.codehaus.plexus.archiver.jar.ManifestException;
  *
  * @since 2.0-beta-6
  */
-// MSITE-665: requiresDependencyResolution workaround for MPLUGIN-253 
+// MSITE-665: requiresDependencyResolution workaround for MPLUGIN-253
 @Mojo( name = "jar", defaultPhase = LifecyclePhase.PACKAGE, requiresDependencyResolution = ResolutionScope.TEST,
        requiresReports = true )
 public class SiteJarMojo
@@ -137,10 +137,7 @@ public class SiteJarMojo
             return;
         }
 
-        if ( !outputDirectory.exists() )
-        {
-            super.execute();
-        }
+        super.execute();
 
         try
         {