You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by lt...@apache.org on 2012/06/18 10:30:38 UTC

svn commit: r1351233 - in /maven: doxia/doxia-tools/trunk/doxia-integration-tools/src/main/java/org/apache/maven/doxia/tools/ plugins/trunk/maven-site-plugin/ plugins/trunk/maven-site-plugin/src/it/MSITE-644/

Author: ltheussl
Date: Mon Jun 18 08:30:38 2012
New Revision: 1351233

URL: http://svn.apache.org/viewvc?rev=1351233&view=rev
Log:
[MSITE-644] NullPointerException when site URL is not defined in distributionManagement

Added:
    maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/
    maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/invoker.properties   (with props)
    maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/pom.xml   (with props)
Modified:
    maven/doxia/doxia-tools/trunk/doxia-integration-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
    maven/plugins/trunk/maven-site-plugin/pom.xml

Modified: maven/doxia/doxia-tools/trunk/doxia-integration-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
URL: http://svn.apache.org/viewvc/maven/doxia/doxia-tools/trunk/doxia-integration-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java?rev=1351233&r1=1351232&r2=1351233&view=diff
==============================================================================
--- maven/doxia/doxia-tools/trunk/doxia-integration-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java (original)
+++ maven/doxia/doxia-tools/trunk/doxia-integration-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java Mon Jun 18 08:30:38 2012
@@ -1464,6 +1464,11 @@ public class DefaultSiteTool
 
     private static String urlEncode( final String url )
     {
+        if ( url == null )
+        {
+            return null;
+        }
+
         try
         {
             return new File( url ).toURI().toURL().toExternalForm();

Modified: maven/plugins/trunk/maven-site-plugin/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-site-plugin/pom.xml?rev=1351233&r1=1351232&r2=1351233&view=diff
==============================================================================
--- maven/plugins/trunk/maven-site-plugin/pom.xml (original)
+++ maven/plugins/trunk/maven-site-plugin/pom.xml Mon Jun 18 08:30:38 2012
@@ -312,9 +312,9 @@ under the License.
     </dependency>
 
     <dependency>
-      <groupId>org.apache.maven.shared</groupId>
-      <artifactId>maven-doxia-tools</artifactId>
-      <version>1.4</version>
+      <groupId>org.apache.maven.doxia</groupId>
+      <artifactId>doxia-integration-tools</artifactId>
+      <version>1.5-SNAPSHOT</version>
       <exclusions>
         <exclusion>
           <groupId>org.apache.maven</groupId>

Added: maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/invoker.properties
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/invoker.properties?rev=1351233&view=auto
==============================================================================
--- maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/invoker.properties (added)
+++ maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/invoker.properties Mon Jun 18 08:30:38 2012
@@ -0,0 +1 @@
+invoker.nonRecursive = true

Propchange: maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/invoker.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/invoker.properties
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/pom.xml?rev=1351233&view=auto
==============================================================================
--- maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/pom.xml (added)
+++ maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/pom.xml Mon Jun 18 08:30:38 2012
@@ -0,0 +1,57 @@
+<?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>test-site</groupId>
+  <artifactId>no-url</artifactId>
+  <version>1.0-SNAPSHOT</version>
+  <packaging>pom</packaging>
+  <name>MSITE-644</name>
+
+  <distributionManagement>
+    <site>
+      <id>site</id>
+      <!-- missing url -->
+    </site>
+  </distributionManagement>
+
+  <build>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <artifactId>maven-site-plugin</artifactId>
+          <version>@project.version@</version>
+          <configuration>
+            <generateReports>false</generateReports>
+          </configuration>
+        </plugin>
+      </plugins>
+    </pluginManagement>
+  </build>
+
+  <modules>
+    <module>module</module>
+  </modules>
+
+</project>

Propchange: maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/trunk/maven-site-plugin/src/it/MSITE-644/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision