ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From emount...@amadeus.net
Subject Re: $ at end of property value
Date Tue, 27 Jun 2000 07:54:11 GMT
Get the latest CVS version: Conor MacNeill has committed a patch for this.
Incidentally, you should use $$ to represent $ in your build.xml (if you don't
make that change, the example you give still won't work the way you expect).

Cheers,
:E




From: "Colin 't Hart" <cthart@gbs.com.au>  on 27/06/2000 04:52 GMT

Please respond to ant-dev@jakarta.apache.org
                                                                                
                                                                                
                                                                                


|--------->
|         |
|--------->
  >--------------------------------------------------------------------------->
  |                                                                           |
  >--------------------------------------------------------------------------->
  >-------------------------------------------|
  |                                           |
  >-------------------------------------------|
|--------->
|To:      |
|--------->
  >--------------------------------------------------------------------------->
  |ant-dev@jakarta.apache.org                                                 |
  >--------------------------------------------------------------------------->
  >-------------------------------------------|
  |                                           |
  |                                           |
  >-------------------------------------------|
|--------->
|cc:      |
|--------->
  >--------------------------------------------------------------------------->
  |"Colin 't Hart" <cthart@gbs.com.au> (bcc: Eric Mountain/NCE/AMADEUS)       |
  >--------------------------------------------------------------------------->
  >-------------------------------------------|
  |                                           |
  |                                           |
  >-------------------------------------------|
|--------->
|         |
|--------->
  >--------------------------------------------------------------------------->
  |                                                                           |
  >--------------------------------------------------------------------------->
  >-------------------------------------------|
  |                                           |
  >-------------------------------------------|
|--------->
|Subject: |
|--------->
  >--------------------------------------------------------------------------->
  |$ at end of property value                                                 |
  >--------------------------------------------------------------------------->
  >-------------------------------------------|
  |                                           |
  >-------------------------------------------|







Hello,

There seems to be a problem with Ant when there is a dollar sign ($)
at the end of a property value,

eg:

<property name="version" value="$Revision: $" />

reports

java.lang.StringIndexOutOfBoundsException: String index out of range: 12
        at java.lang.String.charAt(Compiled Code)
        at org.apache.tools.ant.ProjectHelper.replaceProperties(Compiled
Code)
        at org.apache.tools.ant.ProjectHelper.configure(Compiled Code)
        at org.apache.tools.ant.ProjectHelper.configureProject(Compiled
Code)
        at
org.apache.tools.ant.ProjectHelper.configureProject(ProjectHelper.java:134)
        at org.apache.tools.ant.Main.runBuild(Compiled Code)
        at org.apache.tools.ant.Main.main(Compiled Code)


Ant seems to want to check that the next character is a '{'.

Please CC me on replies.

Cheers,

Colin

Colin 't Hart               tel: +61 (03) 6223 1999
Systems Analyst             fax: +61 (03) 6223 1988
Geographic Business Systems
PO Box 844 SANDY BAY, Tasmania 7006





Mime
View raw message