ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hi...@apache.org
Subject svn commit: r1078007 - /ant/site/xooki/antlib.xml
Date Fri, 04 Mar 2011 15:32:52 GMT
Author: hibou
Date: Fri Mar  4 15:32:52 2011
New Revision: 1078007

URL: http://svn.apache.org/viewvc?rev=1078007&view=rev
Log:
Make the xooki dir parametrable

Modified:
    ant/site/xooki/antlib.xml

Modified: ant/site/xooki/antlib.xml
URL: http://svn.apache.org/viewvc/ant/site/xooki/antlib.xml?rev=1078007&r1=1078006&r2=1078007&view=diff
==============================================================================
--- ant/site/xooki/antlib.xml (original)
+++ ant/site/xooki/antlib.xml Fri Mar  4 15:32:52 2011
@@ -76,6 +76,7 @@
     <scriptdef name="print" language="javascript">
         <attribute name="src"/>
         <attribute name="dest"/>
+        <attribute name="xookidir"/>
         <attribute name="checkUpToDate"/>
         <![CDATA[
             importClass(java.io.File);
@@ -83,6 +84,11 @@
           var file = new File(attributes.get("src"));
           var destFile = new File(attributes.get("dest"));
 
+          var xookidir = attributes.get("xookidir");
+          if (xookidir == null) {
+              xookidir = project.getProperty("basedir") + "/xooki";
+          }
+
       var basedir = file.getParent();
       var filename = file.getName();
 
@@ -106,7 +112,7 @@
             exec.setDir(new File(basedir));
             exec.setExecutable("jrunscript");
             exec.setTaskName("print");
-            exec.createArg().setValue(project.getProperty("basedir")+"/xooki/xooki.js");
+            exec.createArg().setValue(xookidir+"/xooki.js");
             exec.createArg().setValue(filename);
             exec.createArg().setValue(destFile);
             exec.createArg().setValue("print");



Mime
View raw message