Reputation: 747
In STS 3.7.3 where I one Maven project.
When I run maven install, it will download dependencies from some remote repositories, however The dependencies are placed in a folder named "%USERPROFILE%" (.m2 is inside this folder) which is created inside the project root folder.
Don´t know why is being created there and not in the user´s home (in windows, C:\Users) .
STS is Using an external maven installation For the Maven Configuration in STS for Maven (Under Windows -> Preferences -> Maven) 1) I am using a custom user settings which include some remote repositories (settings.xml is C:\maven\settings.xml)
2) Local Repository variable says: C:\sts-3.7.3.RELEASE-64\%USERPROFILE%.m2\repository (This is not editable)
would like the local repository to use the user´s home folder. Any help?
Upvotes: 3
Views: 2154
Reputation: 4521
Probably you can fix that editing the file:
C:\maven\settings.xml
Maybe the path that you have there starts with a .
setting the repository to the path where you are starting the maven process.
In this XML you can inform the tag with the path that you want to be the maven repository.
<localRepository>/path/to/local/repo</localRepository>
Upvotes: 2