Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>First of all: if you wish to customize settings.xml, do not touch the one in maven distro - instead, create a new file in <code>$HOME/.m2/settings.xml</code> where maven finds and uses it.</p> <p><strong>As the very first step</strong>, I recommend you to not use settings.xml at all. Create a supersimple maven project, and try to compile it:</p> <pre><code>mvn clean install </code></pre> <p><strong>Second step</strong></p> <p>Use very simple settings.xml:</p> <ul> <li>you probably do not need proxy</li> <li>servers part is needed only for publishing artifacts to a maven repository; that's not important at the beginning</li> <li>here it is:</li> </ul> <pre class="lang-xml prettyprint-override"><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;settings&gt; &lt;mirrors&gt; &lt;mirror&gt; &lt;id&gt;repos&lt;/id&gt; &lt;mirrorOf&gt;*&lt;/mirrorOf&gt; &lt;name&gt;internal mirror&lt;/name&gt; &lt;url&gt;https://jenkins.web.jw.local/artifactory/repo1&lt;/url&gt; &lt;/mirror&gt; &lt;/mirrors&gt; &lt;!-- TODO: the proxy part here --&gt; &lt;/settings&gt; </code></pre> <p>This assumes that you use inhouse maven repository, for instance <a href="http://nexus.sonatype.com" rel="nofollow">Nexus</a> or <a href="http://www.jfrog.com/" rel="nofollow">Artifactory</a>.</p> <p>Using maven repo makes only sense if your projects are not happy with deps available in the <a href="https://repository.sonatype.org" rel="nofollow">Maven Central Repository</a> - otherwise, you can safely go without it. <em>(let's neglect the performance effect of repoman for now)</em></p> <p><strong>Now,</strong> add some java sources, dependencies etc. - and watch how new depenencies get automatically downloaded to your local repository...</p> <p><strong>Third step</strong></p> <p>Learn how to add further repositories to your repository manager (group "public" on Nexus)...</p> <p>The rest is probably subject of further research.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload