A friendly place for programming greenhorns!
Big Moose Saloon
Search
|
Java FAQ
|
Recent Topics
Register / Login
JavaRanch
»
Java Forums
»
Engineering
»
Ant, Maven and Other Build Tools
Author
How to modify an INI configuration file via ANT build.xml ?
Jeff Tanner
Greenhorn
Joined: Aug 09, 2010
Posts: 6
posted
Nov 04, 2012 11:31:01
0
Hi
Through an
ANT
build.xml
, I want to modify a setting within a
project's config.ini
file.
For example, from default setting:
app_service_api=
UNDEFINED
to a setting defined within build.xml:
app_service_api=
QA
How can I do this
Thanks
Jeff in Seattle
Peter Johnson
author
Bartender
Joined: May 14, 2008
Posts: 5543
I like...
posted
Nov 04, 2012 19:48:56
0
You need to add a <filterchain> section to the <copy> task and use the <replacetokens> option (or some other filter chain option). See:
http://ant.apache.org/manual/Types/filterchain.html
Here is a discussion I had about this earlier this year:
http://www.coderanch.com/t/566206/tools/Modify-build-xml-replace-words#2571618
JBoss In Action
I agree. Here's the link:
http://ej-technologies/jprofiler
- if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
subject: How to modify an INI configuration file via ANT build.xml ?
Similar Threads
ANT Task to modify XML files?
PVCS task in ANT - unable t run from WSAD
Execute Ant script with Java file
calling perl program thru Ant task
Eclipse and ANT
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter