You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by us...@apache.org on 2012/09/20 22:39:27 UTC

svn commit: r1388206 - /lucene/dev/branches/solr3733/solr/common-build.xml

Author: uschindler
Date: Thu Sep 20 20:39:26 2012
New Revision: 1388206

URL: http://svn.apache.org/viewvc?rev=1388206&view=rev
Log:
SOLR-3733: Fix the Solr->Lucene Javadocs URL task to be easier and consistent if directory not yet exists

Modified:
    lucene/dev/branches/solr3733/solr/common-build.xml

Modified: lucene/dev/branches/solr3733/solr/common-build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/solr3733/solr/common-build.xml?rev=1388206&r1=1388205&r2=1388206&view=diff
==============================================================================
--- lucene/dev/branches/solr3733/solr/common-build.xml (original)
+++ lucene/dev/branches/solr3733/solr/common-build.xml Thu Sep 20 20:39:26 2012
@@ -25,9 +25,6 @@
   
   <property name="Name" value="Solr" />
   <property name="version" value="5.0-SNAPSHOT"/>
-  <condition property="version.contains.SNAPSHOT">
-    <contains casesensitive="true" string="${version}" substring="-SNAPSHOT"/>
-  </condition>
   <property name="fullname" value="apache-${ant.project.name}"/>
   <property name="fullnamever" value="${fullname}-${version}"/>
   <property name="final.name" value="${fullnamever}"/>
@@ -278,23 +275,19 @@
     </sequential>
   </macrodef>
 
-  <target name="define-lucene-javadoc-url"
-          depends="define-lucene-javadoc-url-SNAPSHOT,define-lucene-javadoc-url-release"/>
-
-  <target name="define-lucene-javadoc-url-SNAPSHOT" if="version.contains.SNAPSHOT">
-    <makeurl file="${common.dir}/build/docs/" validate="false" property="lucene.javadoc.url"/>
-  </target>
-
-  <target name="define-lucene-javadoc-url-release" unless="version.contains.SNAPSHOT">
-    <loadproperties>
-      <propertyresource name="version"/>
-      <filterchain>
-        <replaceregex pattern="[.]" replace="_" flags="g"/>
-        <prefixlines prefix="underscore.version="/>
-      </filterchain>
-    </loadproperties>
-    <property name="lucene.javadoc.url"
-              value="http://lucene.apache.org/java/${underscore.version}/"/>
+  <target name="define-lucene-javadoc-url">
+    <script language="javascript"><![CDATA[
+      var url, version = project.getProperty('version');
+      if (version.contains('-SNAPSHOT')) {
+        importClass(java.io.File);
+        url = new File(project.getProperty('common.dir'), 'build' + File.separator + 'docs').toURI().toASCIIString();
+        if (!(/\/$/.test(url))) url += '/';
+      } else {
+        version = version.replace('.', '_');
+        url = 'http://lucene.apache.org/java/' + version + '/';
+      }
+      project.setProperty('lucene.javadoc.url', url);
+    ]]></script>
   </target>
 
   <target name="jar-src" depends="init">



RE: svn commit: r1388206 - /lucene/dev/branches/solr3733/solr/common-build.xml

Posted by Steven A Rowe <sa...@syr.edu>.
> +        url = 'http://lucene.apache.org/java/' + version + '/';

Shouldn't this be /core/ instead of /java/ ?

-----Original Message-----
From: Robert Muir [mailto:rcmuir@gmail.com] 
Sent: Thursday, September 20, 2012 4:47 PM
To: dev@lucene.apache.org
Subject: Re: svn commit: r1388206 - /lucene/dev/branches/solr3733/solr/common-build.xml

thanks!

it looks much simpler....crossing fingers 'ant nightly-smoke' passes now

On Thu, Sep 20, 2012 at 4:39 PM,  <us...@apache.org> wrote:
> Author: uschindler
> Date: Thu Sep 20 20:39:26 2012
> New Revision: 1388206
>
> URL: http://svn.apache.org/viewvc?rev=1388206&view=rev
> Log:
> SOLR-3733: Fix the Solr->Lucene Javadocs URL task to be easier and consistent if directory not yet exists
>
> Modified:
>     lucene/dev/branches/solr3733/solr/common-build.xml
>
> Modified: lucene/dev/branches/solr3733/solr/common-build.xml
> URL: http://svn.apache.org/viewvc/lucene/dev/branches/solr3733/solr/common-build.xml?rev=1388206&r1=1388205&r2=1388206&view=diff
> ==============================================================================
> --- lucene/dev/branches/solr3733/solr/common-build.xml (original)
> +++ lucene/dev/branches/solr3733/solr/common-build.xml Thu Sep 20 20:39:26 2012
> @@ -25,9 +25,6 @@
>
>    <property name="Name" value="Solr" />
>    <property name="version" value="5.0-SNAPSHOT"/>
> -  <condition property="version.contains.SNAPSHOT">
> -    <contains casesensitive="true" string="${version}" substring="-SNAPSHOT"/>
> -  </condition>
>    <property name="fullname" value="apache-${ant.project.name}"/>
>    <property name="fullnamever" value="${fullname}-${version}"/>
>    <property name="final.name" value="${fullnamever}"/>
> @@ -278,23 +275,19 @@
>      </sequential>
>    </macrodef>
>
> -  <target name="define-lucene-javadoc-url"
> -          depends="define-lucene-javadoc-url-SNAPSHOT,define-lucene-javadoc-url-release"/>
> -
> -  <target name="define-lucene-javadoc-url-SNAPSHOT" if="version.contains.SNAPSHOT">
> -    <makeurl file="${common.dir}/build/docs/" validate="false" property="lucene.javadoc.url"/>
> -  </target>
> -
> -  <target name="define-lucene-javadoc-url-release" unless="version.contains.SNAPSHOT">
> -    <loadproperties>
> -      <propertyresource name="version"/>
> -      <filterchain>
> -        <replaceregex pattern="[.]" replace="_" flags="g"/>
> -        <prefixlines prefix="underscore.version="/>
> -      </filterchain>
> -    </loadproperties>
> -    <property name="lucene.javadoc.url"
> -              value="http://lucene.apache.org/java/${underscore.version}/"/>
> +  <target name="define-lucene-javadoc-url">
> +    <script language="javascript"><![CDATA[
> +      var url, version = project.getProperty('version');
> +      if (version.contains('-SNAPSHOT')) {
> +        importClass(java.io.File);
> +        url = new File(project.getProperty('common.dir'), 'build' + File.separator + 'docs').toURI().toASCIIString();
> +        if (!(/\/$/.test(url))) url += '/';
> +      } else {
> +        version = version.replace('.', '_');
> +        url = 'http://lucene.apache.org/java/' + version + '/';
> +      }
> +      project.setProperty('lucene.javadoc.url', url);
> +    ]]></script>
>    </target>
>
>    <target name="jar-src" depends="init">
>
>



-- 
lucidworks.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Re: svn commit: r1388206 - /lucene/dev/branches/solr3733/solr/common-build.xml

Posted by Robert Muir <rc...@gmail.com>.
thanks!

it looks much simpler....crossing fingers 'ant nightly-smoke' passes now

On Thu, Sep 20, 2012 at 4:39 PM,  <us...@apache.org> wrote:
> Author: uschindler
> Date: Thu Sep 20 20:39:26 2012
> New Revision: 1388206
>
> URL: http://svn.apache.org/viewvc?rev=1388206&view=rev
> Log:
> SOLR-3733: Fix the Solr->Lucene Javadocs URL task to be easier and consistent if directory not yet exists
>
> Modified:
>     lucene/dev/branches/solr3733/solr/common-build.xml
>
> Modified: lucene/dev/branches/solr3733/solr/common-build.xml
> URL: http://svn.apache.org/viewvc/lucene/dev/branches/solr3733/solr/common-build.xml?rev=1388206&r1=1388205&r2=1388206&view=diff
> ==============================================================================
> --- lucene/dev/branches/solr3733/solr/common-build.xml (original)
> +++ lucene/dev/branches/solr3733/solr/common-build.xml Thu Sep 20 20:39:26 2012
> @@ -25,9 +25,6 @@
>
>    <property name="Name" value="Solr" />
>    <property name="version" value="5.0-SNAPSHOT"/>
> -  <condition property="version.contains.SNAPSHOT">
> -    <contains casesensitive="true" string="${version}" substring="-SNAPSHOT"/>
> -  </condition>
>    <property name="fullname" value="apache-${ant.project.name}"/>
>    <property name="fullnamever" value="${fullname}-${version}"/>
>    <property name="final.name" value="${fullnamever}"/>
> @@ -278,23 +275,19 @@
>      </sequential>
>    </macrodef>
>
> -  <target name="define-lucene-javadoc-url"
> -          depends="define-lucene-javadoc-url-SNAPSHOT,define-lucene-javadoc-url-release"/>
> -
> -  <target name="define-lucene-javadoc-url-SNAPSHOT" if="version.contains.SNAPSHOT">
> -    <makeurl file="${common.dir}/build/docs/" validate="false" property="lucene.javadoc.url"/>
> -  </target>
> -
> -  <target name="define-lucene-javadoc-url-release" unless="version.contains.SNAPSHOT">
> -    <loadproperties>
> -      <propertyresource name="version"/>
> -      <filterchain>
> -        <replaceregex pattern="[.]" replace="_" flags="g"/>
> -        <prefixlines prefix="underscore.version="/>
> -      </filterchain>
> -    </loadproperties>
> -    <property name="lucene.javadoc.url"
> -              value="http://lucene.apache.org/java/${underscore.version}/"/>
> +  <target name="define-lucene-javadoc-url">
> +    <script language="javascript"><![CDATA[
> +      var url, version = project.getProperty('version');
> +      if (version.contains('-SNAPSHOT')) {
> +        importClass(java.io.File);
> +        url = new File(project.getProperty('common.dir'), 'build' + File.separator + 'docs').toURI().toASCIIString();
> +        if (!(/\/$/.test(url))) url += '/';
> +      } else {
> +        version = version.replace('.', '_');
> +        url = 'http://lucene.apache.org/java/' + version + '/';
> +      }
> +      project.setProperty('lucene.javadoc.url', url);
> +    ]]></script>
>    </target>
>
>    <target name="jar-src" depends="init">
>
>



-- 
lucidworks.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org