Hi,
I have a bit of a problem with the <nant> task and can't see what's wrong.
Below is a copy of my build script and the associated output. According to
the documentation, I should be able to use a property value in my current
project to pass through top a new NAnt instance, but it seems to be failing.
Am I missing something really stupid or is it a bug? I'm using NAnt 0.84
As you can see below, the property ${propfile} appears to be defined until I
use it in the nested <properties> element on the <nant> task.
Cheers,
Bill
Build Script
========
<project name="DailyBuild" default="compile" basedir=".">
<target name="init">
<tstamp property="build.date" pattern="dd MMM yyyy HH:mm" />
<echo message="${build.date}"/>
<echo message="Performing Daily Build ..."/>
<property name="webserver.install.dir" value="install/webserver" />
<property name="appserver.install.dir" value="install/appserver" />
<echo message="nant.home=${nant.home}" />
<echo message="src.home=${src.home}" />
<echo message="vssarchive.home=${vssarchive.home}" />
<echo message="vssproject.home=${vssproject.home}" />
<echo message="vssversion=${vssversion}" />
<echo message="systembuild.file=${systembuild.file}" />
<echo message="propfile=${propfile}" />
<echo message="vss.user=${vss.user}" />
<echo message="vss.password=${vss.password}" />
</target>
<target name="prepare" depends="init"/>
<!--Delete exiting source-->
<target name="clean" depends="prepare">
<!--delete dir="${src.home}" failonerror="false" /-->
</target>
<!--Extract Latest Version of Source-->
<target name="getsource" depends="clean">
<!--vssget
localpath="${src.home}"
recursive="true"
dbpath="${vssarchive.home}"
path="${vssproject.home}"
user="${vss.user}"
password="${vss.password}" /-->
</target>
<!--Build the system-->
<target name="compile" depends="getsource">
<echo message="propfile=${propfile}" />
<nant buildfile="${src.home}/ExWebGold.build" target="all"
inheritall="false">
<properties>
<property name="prop.file" value="${propfile}" />
</properties>
</nant>
</target>
<!--Deploy the system to the test server-->
<target name="deploy" depends="compile">
<!-- Create the install sets -->
<nant buildfile="${src.home}/install.build" target="allservers"
inheritall="false">
<properties>
<property name="webserver.install.dir"
value="$src.home}/${webserver.install.dir}" />
<property name="appserver.install.dir"
value="$src.home}/${appserver.install.dir}" />
</properties>
</nant>
</target>
</project>
Output to log
=========
Buildfile: file:///C:/DailyBuild/DailyBuild.build
Target(s) specified: compile
init:
[tstamp] 05 April 2004 08:43:34.
[echo] 05 Apr 2004 08:43
[echo] Performing Daily Build ...
[echo] propfile=C:\MySystem\properties.build
[echo] nant.home=C:\NAnt_0.84
[echo] src.home=C:\MySystem
[echo] vssarchive.home=\\SERVER\Share\MySystem\srcsafe.ini
[echo] vssproject.home=$/Source/Build/MySystem
[echo] vssversion=
[echo] systembuild.file=MySystem.build
[echo] propfile=C:\MySystem\properties.build
[echo] vss.user=guest
[echo] vss.password=
prepare:
clean:
getsource:
compile:
[echo] propfile=C:\MySystem\properties.build
[nant] C:\MySystem/MySystem.build all
BUILD FAILED
C:\DailyBuild\DailyBuild.build(56,18):
Property 'propfile' has not been set.
Total time: 0.2 seconds.
______________________________________________________________
CONFIDENTIALITY NOTICE
This communication and the information it contains is intended for the person or
organisation to whom it is addressed. Its contents are confidential and may be
protected in law. Unauthorised use, copying or disclosure of any of it may be
unlawful. If you are not the intended recipient, please contact us immediately.
The contents of any attachments in this e-mail may contain software viruses, which
could damage your own computer system. While Marlborough Stirling has taken every
reasonable precaution to minimise this risk, we cannot accept liability for any
damage, which you sustain as a result of software viruses. You should carry out your
own virus checking procedure before opening any attachment.
Marlborough Stirling plc, Registered in England and Wales
Registered No. 3008820,
Allen Jones House, Jessop Avenue, Cheltenham, Gloucestershire, GL50 3SH
Tel: 01242 547000 Fax: 01242 547100
http://www.marlborough-stirling.com
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id70&alloc_id638&op=click
_______________________________________________
Nant-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/nant-users