You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by "Braden N. McDaniel" <bn...@learningsoft.net> on 2000/08/16 23:35:10 UTC

Re: How to use $ in a ANT exec command

On 8 Aug 2000, Stefan Bodewig wrote:

> Which version of Ant are you using? For current CVS:
> 
> bodewig@sbodewig /tmp >cat > build.xml
> <project name="test" default="tryme" basedir=".">
> <property name="helper.classes" value="Helper$$1.class:Helper$$2.classs"/>
> 
> <target name="tryme">
> <echo message="${helper.classes}"/>
> </target>
> </project>
> bodewig@sbodewig /tmp >ant
> Buildfile: build.xml
> 
> tryme:
> Helper$1.class:Helper$2.classs
> 
> BUILD SUCCESSFUL
> 
> Total time: 0 seconds
> bodewig@sbodewig /tmp >ant -version
> Ant version 1.2alpha compiled on August 8 2000
> 
> I get the expected result - and the code that does the ${} expansion
> (and handles the $$ case) didn't change since Ant 1.1 IIRC.

I am having a similar problem; I'm trying to use a $ literal in an exec
command. '$$' does not work--it causes the remainder of the indentifier
(after the $) to evaporate (results observed using echo). I am using Ant
1.1.

-- 
Braden N. McDaniel                           bnmcdaniel@learningsoft.net
Java Developer, LearningSoft                 <http://www.learningsoft.net>