I have a Maven web application with text files in
src/main/webapp/textfilesdir
As I understand it, during the package phase this te
Another solution from me, sorry for being late to the party but still might be useful for some people. Solution above simply didn't work for me because I had overlays in place and therefore using the replacer plugin was hard in the main source. Hence, I used maven-war-plugin to generate the temporary directory for me in the prepare-package phase and have replacer plugin to manipulate it and release the war from that directory so that nothing else overrides with it.
maven-war-plugin
prepare
prepare-package
exploded
${project.build.directory}/${project.build.finalName}-patched/
default-war
package
war
true
${project.build.directory}/${project.build.finalName}-patched/
com.google.code.maven-replacer-plugin
replacer
prepare-package
replace
${project.build.directory}/${project.build.finalName}-patched/fileToBeChanged.txt
ValueToChange
ValueToReplace