DevOps / Maven Interview questions II
Can we change the .m2 folder to any other name like .p2 or something? How?
Yes. The local repo folder name can be changed by updating in the settings.xml. localRepository property in the file holds the path of the build system's local repository. The default value is ${user.home}/.m2/repository and it can be changed.
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"> <localRepository>${user.home}/.m2/repository</localRepository> </settings>
More Related questions...