Change Maven Local Repository Path
To change the default path of the Maven local repository, you can modify it in the Maven configuration file settings.xml. Locate the
By default, the settings.xml file is located in the conf folder within the Maven installation directory. Alternatively, you can modify the path of the Maven local repository by creating a .m2 folder in the user directory and placing a settings.xml file inside it.
After making the changes, simply run Maven’s build command again to download the dependencies to the new local repository path.