I've been looking for a solution on how to customized the maven settings for different project but there was none. So, I've created my own solution on this blog on how to do it, instead of customizing each project, I basically configure it on each workspace. My practice is one workspace for each project. This is what I have done so far:
Step 1:
Regarding changing the path of your local repository, you need to add the following code inside the settings.xml file from our maven conf directory:
<localRepository>D:/Devtools/Maven/Repository</localRepository>
Step 1:
- Open Eclipse or Springsource Tool Suite (STS) IDE
- Click Window - Preferences
- In Filter box, enter "Maven"
- Click the Installation and add the Maven home that you have in your computer. In my case I downloaded Maven 3.2.1 then extracted the TAR.GZ file to C:\Devtools\Apache\Maven\3.2.1
- Click User Settings then Browse the settings.xml file. In my case the location of the settings.xml is C:\Devtools\Apache\Maven\3.2.1\conf\settings.xml then click Update Settings and click Apply then Click OK.
Regarding changing the path of your local repository, you need to add the following code inside the settings.xml file from our maven conf directory:
<localRepository>D:/Devtools/Maven/Repository</localRepository>