java - Change .m2 directory for each build -
we build artifacts our alpha,beta , stage environments same machine. each environment run on different release version , cannot reuse .m2, because alpha build populates future release artifacts in m2 , incorrect beta , stage. every time build, delete old m2 directory , repopulate environment specific code base. hope explains little better
you can change settings file -s , private repo -dmaven.repo.local. between these 2 pretty same different .m2.
mvn -s codebase-specific-maven-settings.xml -dmaven.repo.local=/path/to/codebase-specific-repo
Comments
Post a Comment