ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Conor MacNeill <>
Subject Re: setting property using <script> task
Date Mon, 07 Apr 2003 23:50:21 GMT
On Tue, 8 Apr 2003 06:25 am, Woo, Chen Ching wrote:
> I need to do some processing using the <script> task and set a project
> property at the end, but it doesn't seem to work. Can some one point me to
> the right direction ?

Don't use antcall. It sets the property in the sub-project but the calling 
project is unaffected. Try this instead

<?xml version="1.0" encoding="UTF-8"?>
<project name="test" default="default" basedir=".">
  <target name="default" depends="myFunc">
    <echo message="${hello}"/>
  <target name="myFunc">
        <script language="javascript">
      project.setNewProperty("hello", "it's me !");



Conor MacNeill

View raw message