Friday, 18 July 2014

ANT Andrid replace string.xml during build



Using ANT I have a custom build routine that builds my Android application and compiles the APK. I know already how to include a custom the assets file but I'm hoping to use a custom strings file. Currently I have multiple directories that specify different builds depending on the custom requirements.


Inside these build folders I have two files release.xml, and release-build.xml however I don't know where to put the following line from this similar question. Custom ant task to automate android apk generation



<replace file="res/values/strings.xml" token="@@@" value="http://myUrl"/>


Ideally rather than replacing a single property I would like to use a different strings.xml file during the build. Is this possible, if so how?


No comments:

Post a Comment