On Sep 19, 2008, at 3:43 PM, Ignacio Coloma wrote:
> Is there any way of replacing properties in a file while it's being
> copied? I have a file that contains
> And I want to copy it and replace the properties automatically.
> With ant, I would have used a filterchain (expandproperties) but
> with gradle I'm a little lost:
> file: "fromfile.xml",
> tofile: "tofile.xml"
> //chain: << magic happens here
You can bundle multiple ant statements in one context:
The resources task has build in functionality for this. See the
(rather thin documentation) in: http://www.gradle.org/api/0.4/org/ gradle/api/tasks/Resources.html
Under the hood it delegates to Ant. The only limitation right now is
that it uses the default Ant begin and end tokens (@). You can't
specify other ones. If you would need this behavior, please file a