How can I transform a .properties file during a Gradle build?
You can use the ant.propertyfile task:
ant.propertyfile(
file: "myfile.properties") {
entry( key: "propertyName", value: "propertyValue")
entry( key: "anotherProperty", operation: "del")
}
You should be able to fire off an ant "replace" task that does what you want: http://ant.apache.org/manual/Tasks/replace.html
ant.replace(file: "blah", token: "wibble", value: "flibble")