Nested variables

"Labout, Douglas" <[email protected]> Mon, 17 Jun 2013 15:09:21 +0000
Newsgroups gmane.comp.windows.dotnet.nant.user
Message-ID <[email protected]>
--===============6285314546996080348==
Content-Language: en-US
Content-Type: multipart/alternative;
	boundary="_000_5E3197C77D5A9F419794D41CB40CFA7B0CF372F5ES05firstbankfb_"

--_000_5E3197C77D5A9F419794D41CB40CFA7B0CF372F5ES05firstbankfb_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Hello,
I'm working on converting an Ant script to Nant and have ran into an issue =
with joining several variables together in Nant.

Below is the original Ant script in which it pulls information from a prope=
rties file and uses the information to feed the build. The project starts b=
y looping through build order (NETDLLS, App) and then uses that variable to=
 prepend to the ProjectName to check out of StarTeam.

Project.Build.Order=3DNETDLLs,App

# Windows - .NET DLLs
NETDLLs.ProjectName=3DWindows - .NET DLLs
NETDLLs.ViewName=3DWindows - .NET DLLs
NETDLLs.Label=3D201300722.20130508

ANT script:
<target name=3D"build.project">
      <property name=3D"ProjectName" value=3D"${buildProp.${project.Ord}.Pr=
ojectName}"/>
      <property name=3D"ViewName" value=3D"${buildProp.${project.Ord}.ViewN=
ame}"/>
      <property name=3D"Label" value=3D"${buildProp.${project.Ord}.Label}"/=
>

      <antcall target=3D"checkoutModuleSrc" inheritall=3D"true"/>

Here is what I have come up with in Nant which doesn't seem to be working.

NAnt script:
<target name=3D"build.project">
      <property name=3D"ProjectName" value=3D"${'properties.project.Ord'+'.=
ProjectName'}"/>
      <property name=3D"ViewName" value=3D"${'properties.project.Ord'+'.Vie=
wName'}"/>
      <property name=3D"Label" value=3D"${'properties.project.Ord'+'.Label'=
}"/>
      <echo>${ProjectName} ${ViewName} ${Label}</echo>
      <call target=3D"checkoutModuleSrc"/>

Results of the script at the command line:
checkoutModuleSrc:

     [exec] StarTeam 10.4 Command Line Interface, Build 10.4.8.36
     [exec] Copyright (c) 2003-2008 Borland Software Corporation. All right=
s res
erved.
     [exec] Using ini file: C:\Documents and Settings\All Users\Application=
 Data
\Borland\StarTeam\ConnectionManager.ini
     [exec] Project not found: properties.project.Ord.ProjectName

I would appreciate any help you can provide.

Thanks,
-Doug Labout


The information contained in this electronic communication and any document=
 attached hereto or transmitted herewith is confidential and intended for t=
he exclusive use of the individual or entity named above. If the reader of =
this message is not the intended recipient or the employee or agent respons=
ible for delivering it to the intended recipient, you are hereby notified t=
hat any examination, use, dissemination, distribution or copying of this co=
mmunication or any part thereof is strictly prohibited. If you have receive=
d this communication in error, please immediately notify the sender by repl=
y e-mail and destroy this communication. Thank you.

--_000_5E3197C77D5A9F419794D41CB40CFA7B0CF372F5ES05firstbankfb_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Dus-ascii"=
>
<style>
<!--
@font-face
	{font-family:Calibri}
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:11.0pt;
	font-family:"Calibri","sans-serif"}
a:link, span.MsoHyperlink
	{color:blue;
	text-decoration:underline}
a:visited, span.MsoHyperlinkFollowed
	{color:purple;
	text-decoration:underline}
span.EmailStyle17
	{font-family:"Calibri","sans-serif";
	color:windowtext}
.MsoChpDefault
	{font-family:"Calibri","sans-serif"}
@page WordSection1
	{margin:1.0in 1.0in 1.0in 1.0in}
div.WordSection1
	{}
-->
</style>
</head>
<body lang=3D"EN-US" link=3D"blue" vlink=3D"purple">
<div class=3D"WordSection1">
<p class=3D"MsoNormal">Hello,</p>
<p class=3D"MsoNormal">I&#8217;m working on converting an Ant script to Nan=
t and have ran into an issue with joining several variables together in Nan=
t.</p>
<p class=3D"MsoNormal">&nbsp;</p>
<p class=3D"MsoNormal">Below is the original Ant script in which it pulls i=
nformation from a properties file and uses the information to feed the buil=
d. The project starts by looping through build order (NETDLLS, App) and the=
n uses that variable to prepend to
 the ProjectName to check out of StarTeam.</p>
<p class=3D"MsoNormal">&nbsp;</p>
<p class=3D"MsoNormal">Project.Build.Order=3DNETDLLs,App</p>
<p class=3D"MsoNormal">&nbsp;</p>
<p class=3D"MsoNormal"># Windows - .NET DLLs</p>
<p class=3D"MsoNormal">NETDLLs.ProjectName=3DWindows - .NET DLLs</p>
<p class=3D"MsoNormal">NETDLLs.ViewName=3DWindows - .NET DLLs</p>
<p class=3D"MsoNormal">NETDLLs.Label=3D201300722.20130508</p>
<p class=3D"MsoNormal">&nbsp;</p>
<p class=3D"MsoNormal">ANT script:</p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:navy">&lt;target</spa=
n><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; col=
or:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;build.project&quot;</span><span s=
tyle=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:navy">=
&gt;</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&q=
uot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:black">&nbsp; &nbsp;&=
nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;property</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;ProjectName&quot;</span><span sty=
le=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">value=3D</span><span style=3D"font-size:10.0pt; font-family:&=
quot;Courier New&quot;; color:green">&quot;${buildProp.${project.Ord}.Proje=
ctName}&quot;</span><span style=3D"font-size:10.0pt; font-family:&quot;Cour=
ier New&quot;; color:navy">/&gt;</span><span style=3D"font-size:10.0pt; fon=
t-family:&quot;Courier New&quot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:black">&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;property</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;ViewName&quot;</span><span style=
=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">value=3D</span><span style=3D"font-size:10.0pt; font-family:&=
quot;Courier New&quot;; color:green">&quot;${buildProp.${project.Ord}.ViewN=
ame}&quot;</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier=
 New&quot;; color:navy">/&gt;</span><span style=3D"font-size:10.0pt; font-f=
amily:&quot;Courier New&quot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:black">&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;property</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;Label&quot;</span><span style=3D"=
font-size:10.0pt; font-family:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">value=3D</span><span style=3D"font-size:10.0pt; font-family:&=
quot;Courier New&quot;; color:green">&quot;${buildProp.${project.Ord}.Label=
}&quot;</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier Ne=
w&quot;; color:navy">/&gt;</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:10.0pt; font-family:&quot;C=
ourier New&quot;; color:black">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;antcall</span><span style=3D"font-size:10.0pt; font-famil=
y:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">target=3D</span><span style=3D"font-size:10.0pt; font-family:=
&quot;Courier New&quot;; color:green">&quot;checkoutModuleSrc&quot;</span><=
span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:=
black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">inheritall=3D</span><span style=3D"font-size:10.0pt; font-fam=
ily:&quot;Courier New&quot;; color:green">&quot;true&quot;</span><span styl=
e=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:navy">/&g=
t;</span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:10.0pt; font-family:&quot;C=
ourier New&quot;; color:navy">&nbsp;</span></p>
<p class=3D"MsoNormal">Here is what I have come up with in Nant which doesn=
&#8217;t seem to be working.
<span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color=
:navy"></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:10.0pt; font-family:&quot;C=
ourier New&quot;; color:navy">&nbsp;</span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:10.0pt; font-family:&quot;C=
ourier New&quot;; color:navy">NAnt script:</span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:navy">&lt;target</spa=
n><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; col=
or:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;build.project&quot;</span><span s=
tyle=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:navy">=
&gt;</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&q=
uot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:black">&nbsp; &nbsp;&=
nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;property</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;ProjectName&quot;</span><span sty=
le=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">value=3D</span><span style=3D"font-size:10.0pt; font-family:&=
quot;Courier New&quot;; color:green">&quot;${'properties.project.Ord'&#43;'=
.ProjectName'}&quot;</span><span style=3D"font-size:10.0pt; font-family:&qu=
ot;Courier New&quot;; color:navy">/&gt;</span><span style=3D"font-size:10.0=
pt; font-family:&quot;Courier New&quot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:black">&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;property</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;ViewName&quot;</span><span style=
=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">value=3D</span><span style=3D"font-size:10.0pt; font-family:&=
quot;Courier New&quot;; color:green">&quot;${'properties.project.Ord'&#43;'=
.ViewName'}&quot;</span><span style=3D"font-size:10.0pt; font-family:&quot;=
Courier New&quot;; color:navy">/&gt;</span><span style=3D"font-size:10.0pt;=
 font-family:&quot;Courier New&quot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:black">&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;property</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">name=3D</span><span style=3D"font-size:10.0pt; font-family:&q=
uot;Courier New&quot;; color:green">&quot;Label&quot;</span><span style=3D"=
font-size:10.0pt; font-family:&quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">value=3D</span><span style=3D"font-size:10.0pt; font-family:&=
quot;Courier New&quot;; color:green">&quot;${'properties.project.Ord'&#43;'=
.Label'}&quot;</span><span style=3D"font-size:10.0pt; font-family:&quot;Cou=
rier New&quot;; color:navy">/&gt;</span><span style=3D"font-size:10.0pt; fo=
nt-family:&quot;Courier New&quot;"></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:10.0pt; font-family:&quot;Courier New&quot;; color:black">&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;echo&gt;</span><span style=3D"font-size:10.0pt; font-fami=
ly:&quot;Courier New&quot;; color:black">${ProjectName} ${ViewName} ${Label=
}</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot=
;; color:navy">&lt;/echo&gt;</span><span style=3D"font-size:10.0pt; font-fa=
mily:&quot;Courier New&quot;"></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:10.0pt; font-family:&quot;C=
ourier New&quot;; color:black">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">&lt;call</span><span style=3D"font-size:10.0pt; font-family:&=
quot;Courier New&quot;; color:black">
</span><span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;=
; color:navy">target=3D</span><span style=3D"font-size:10.0pt; font-family:=
&quot;Courier New&quot;; color:green">&quot;checkoutModuleSrc&quot;</span><=
span style=3D"font-size:10.0pt; font-family:&quot;Courier New&quot;; color:=
navy">/&gt;</span></p>
<p class=3D"MsoNormal">&nbsp;</p>
<p class=3D"MsoNormal">Results of the script at the command line:</p>
<p class=3D"MsoNormal">checkoutModuleSrc:</p>
<p class=3D"MsoNormal">&nbsp;</p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp;&nbsp; [exec] StarTeam 10.4 Comman=
d Line Interface, Build 10.4.8.36</p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp;&nbsp; [exec] Copyright (c) 2003-2=
008 Borland Software Corporation. All rights res</p>
<p class=3D"MsoNormal">erved.</p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp;&nbsp; [exec] Using ini file: C:\D=
ocuments and Settings\All Users\Application Data</p>
<p class=3D"MsoNormal">\Borland\StarTeam\ConnectionManager.ini</p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp;&nbsp; <b><span style=3D"color:red=
">[exec] Project not found: properties.project.Ord.ProjectName</span></b></=
p>
<p class=3D"MsoNormal"><b><span style=3D"color:red">&nbsp;</span></b></p>
<p class=3D"MsoNormal">I would appreciate any help you can provide. </p>
<p class=3D"MsoNormal">&nbsp;</p>
<p class=3D"MsoNormal">Thanks,</p>
<p class=3D"MsoNormal">-Doug Labout<b></b></p>
<p class=3D"MsoNormal">&nbsp;</p>
</div>
<br>
<i>The information contained in this electronic communication and any docum=
ent attached hereto or transmitted herewith is confidential and intended fo=
r the exclusive use of the individual or entity named above. If the reader =
of this message is not the intended
 recipient or the employee or agent responsible for delivering it to the in=
tended recipient, you are hereby notified that any examination, use, dissem=
ination, distribution or copying of this communication or any part thereof =
is strictly prohibited. If you have
 received this communication in error, please immediately notify the sender=
 by reply e-mail and destroy this communication. Thank you.
<i></i></i>
</body>
</html>

--_000_5E3197C77D5A9F419794D41CB40CFA7B0CF372F5ES05firstbankfb_--


--===============6285314546996080348==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
--===============6285314546996080348==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
NAnt-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nant-users

--===============6285314546996080348==--