You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Peter West <li...@pbw.id.au> on 2013/05/15 04:08:24 UTC

editstring macro

I have posted a discussion and code for a macro to edit a string value, placing the result into a property.  I'm sure various people have done the same sort of thing before, but this might be a handy reference.

http://codepulsive.blogspot.com.au/2013/05/ant-edit-property-values.html

An example build.xml is available at <http://pbw.id.au/editstring/build.xml>.


Peter West

"When the Spirit of truth comes, he will guide you into all the truth..."


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


AW: editstring macro

Posted by "Jan Matèrne (jhm)" <ap...@materne.de>.
No props is one of the developed antlibs, which were never released.
Sources and tests are all available under ASL at ASF servers.
But there is not binary distro, so you must build it yourself (which
shouldn't be more difficult than 
invoking "ant").

Jan

> -----Ursprüngliche Nachricht-----
> Von: Peter West [mailto:lists@pbw.id.au]
> Gesendet: Mittwoch, 15. Mai 2013 23:59
> An: Ant Users List
> Betreff: Re: editstring macro
> 
> Thanks Jan.
> 
> I saw the description of propertyhelper in the manual, but got the
> impression that it was for developing implementations external to the
> distribution.  Is the props antlib part of the standard distribution?
> There is nothing that I could see about props antlib in the downloads
> section of the Apache Props Antlib webpage. Is it part of antunit? I
> couldn't see any indication of that in antunit jar.
> 
> I was after a solution that did _not_ require any additional
> dependencies.
> 
> Peter West
> 
> "When the Spirit of truth comes, he will guide you into all the
> truth..."
> 
> On 15/05/2013, at 3:54 PM, Jan Matèrne (jhm) <ap...@materne.de> wrote:
> 
> > Have you tried Ant Props?
> > http://ant.apache.org/antlibs/props/index.html
> >
> https://svn.apache.org/repos/asf/ant/antlibs/props/trunk/src/tests/ant
> > unit/s
> > tringops-test.xml
> > - testReplaceFirst
> > - testReplaceAll
> > - testPackageMapping
> >
> > Jan
> >
> >> -----Ursprüngliche Nachricht-----
> >> Von: Peter West [mailto:lists@pbw.id.au]
> >> Gesendet: Mittwoch, 15. Mai 2013 04:08
> >> An: Ant Users List
> >> Betreff: editstring macro
> >>
> >> I have posted a discussion and code for a macro to edit a string
> >> value, placing the result into a property.  I'm sure various people
> >> have done the same sort of thing before, but this might be a handy
> reference.
> >>
> >> http://codepulsive.blogspot.com.au/2013/05/ant-edit-property-
> >> values.html
> >>
> >> An example build.xml is available at
> >> <http://pbw.id.au/editstring/build.xml>.
> >>
> >>
> >> Peter West
> >>
> >> "When the Spirit of truth comes, he will guide you into all the
> >> truth..."
> >>
> >>
> >> --------------------------------------------------------------------
> -
> >> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For
> >> additional commands, e-mail: user-help@ant.apache.org
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For
> additional
> > commands, e-mail: user-help@ant.apache.org
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional
> commands, e-mail: user-help@ant.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Re: editstring macro

Posted by Peter West <li...@pbw.id.au>.
Thanks Jan.

I saw the description of propertyhelper in the manual, but got the impression that it was for developing implementations external to the distribution.  Is the props antlib part of the standard distribution? There is nothing that I could see about props antlib in the downloads section of the Apache Props Antlib webpage. Is it part of antunit? I couldn't see any indication of that in antunit jar.

I was after a solution that did _not_ require any additional dependencies.

Peter West

"When the Spirit of truth comes, he will guide you into all the truth..."

On 15/05/2013, at 3:54 PM, Jan Matèrne (jhm) <ap...@materne.de> wrote:

> Have you tried Ant Props?
> http://ant.apache.org/antlibs/props/index.html
> https://svn.apache.org/repos/asf/ant/antlibs/props/trunk/src/tests/antunit/s
> tringops-test.xml
> - testReplaceFirst
> - testReplaceAll
> - testPackageMapping
> 
> Jan
> 
>> -----Ursprüngliche Nachricht-----
>> Von: Peter West [mailto:lists@pbw.id.au]
>> Gesendet: Mittwoch, 15. Mai 2013 04:08
>> An: Ant Users List
>> Betreff: editstring macro
>> 
>> I have posted a discussion and code for a macro to edit a string value,
>> placing the result into a property.  I'm sure various people have done
>> the same sort of thing before, but this might be a handy reference.
>> 
>> http://codepulsive.blogspot.com.au/2013/05/ant-edit-property-
>> values.html
>> 
>> An example build.xml is available at
>> <http://pbw.id.au/editstring/build.xml>.
>> 
>> 
>> Peter West
>> 
>> "When the Spirit of truth comes, he will guide you into all the
>> truth..."
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional
>> commands, e-mail: user-help@ant.apache.org
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


AW: editstring macro

Posted by "Jan Matèrne (jhm)" <ap...@materne.de>.
Have you tried Ant Props?
http://ant.apache.org/antlibs/props/index.html
https://svn.apache.org/repos/asf/ant/antlibs/props/trunk/src/tests/antunit/s
tringops-test.xml
- testReplaceFirst
- testReplaceAll
- testPackageMapping

Jan

> -----Ursprüngliche Nachricht-----
> Von: Peter West [mailto:lists@pbw.id.au]
> Gesendet: Mittwoch, 15. Mai 2013 04:08
> An: Ant Users List
> Betreff: editstring macro
> 
> I have posted a discussion and code for a macro to edit a string value,
> placing the result into a property.  I'm sure various people have done
> the same sort of thing before, but this might be a handy reference.
> 
> http://codepulsive.blogspot.com.au/2013/05/ant-edit-property-
> values.html
> 
> An example build.xml is available at
> <http://pbw.id.au/editstring/build.xml>.
> 
> 
> Peter West
> 
> "When the Spirit of truth comes, he will guide you into all the
> truth..."
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional
> commands, e-mail: user-help@ant.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org