| Try the new Plugin SDK We've released a new Plugin SDK which handles almost all of this Maven tweaking for you. The SDK includes an embedded Maven installation and correct settings.xml that will be kept up to date as necessary. We believe it makes the plugin development process much easier. If you are using the SDK, you won't need this file. For more information, see [here]. |
This is an example settings.xml file for Maven 2. It can be placed in your $HOME/.m2 directory (where is that?) and it will apply to all maven projects that you build. If you would rather, you can make this a per-project settings by including a profile.xml in your project base directory. See Maven's documentation on Build Profile Settings.
If your network requires the use of an HTTP or HTTPS proxy, you'll need to add those to your settings.xml.
<settings>
<pluginGroups>
<pluginGroup>com.atlassian.maven.plugins</pluginGroup>
</pluginGroups>
<servers>
<!--
If you want to deploy your code to the Atlassian Maven repositories, you must be a
Committer. You can request commit rights by emailing developer-relations@atlassian.com.
If you have commit access, use your Atlassian Developer Network username and password.
If you're using Maven 2.1.0 or later (and you really should be; we'll make it a
requirement soon), we *strongly* recommend that you use Maven's password encryption
feature. This removes the need to have your cleartext passwords in this file. See
http://maven.apache.org/guides/mini/guide-encryption.html for instructions.
-->
<server>
<id>atlassian-contrib</id>
<username>yourusername</username>
<password>yourpassword</password> <!-- use encrypted passwords! -->
</server>
<server>
<id>atlassian-contrib-snapshot</id>
<username>yourusername</username>
<password>yourpassword</password> <!-- use encrypted passwords! -->
</server>
<server>
<id>atlassian-documentation</id>
<username>yourusername</username>
<password>yourpassword</password> <!-- use encrypted passwords! -->
</server>
</servers>
<profiles>
<profile>
<id>defaultProfile</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<!--
Information on all Atlassian Maven repositories is available at
http://confluence.atlassian.com/display/DEVNET/Atlassian+Maven+Repositories.
-->
<repositories>
<!--
This is the public Atlassian Maven proxy. It makes artifacts
available from the main Maven repository at ibiblio, Codehaus,
and all other dependencies necessary for building Atlassian
products (except Sun JARs we are not allowed to distribute
ourselves). This should have everything you need to build
a plugin; if something is missing, please open a JIRA issue
at http://developer.atlassian.com/jira/browse/CPDK.
-->
<repository>
<id>central</id>
<url>https://m2proxy.atlassian.com/repository/public</url>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
<checksumPolicy>fail</checksumPolicy>
</snapshots>
<releases>
<enabled>true</enabled>
<checksumPolicy>fail</checksumPolicy>
</releases>
</repository>
<!--
Since JIRA is still using Maven 1, this repository is used for
those Maven 1 artifacts that aren't available in Maven 2.
-->
<repository>
<id>atlassian-m1-repository</id>
<url>https://m2proxy.atlassian.com/repository/m1/</url>
<releases>
<checksumPolicy>fail</checksumPolicy>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>https://m2proxy.atlassian.com/repository/public</url>
<releases>
<enabled>true</enabled>
<checksumPolicy>fail</checksumPolicy>
</releases>
<snapshots>
<checksumPolicy>fail</checksumPolicy>
</snapshots>
</pluginRepository>
</pluginRepositories>
<properties>
<downloadSources>true</downloadSources>
<downloadJavadocs>true</downloadJavadocs>
<!--
If you have a Clover license, specify the filesystem path
to it here.
-->
<!--<clover.licenseLocation>/path/to/clover/license</clover.licenseLocation>-->
</properties>
</profile>
</profiles>
</settings>
Download here





Comments (4)
May 20, 2009
Hasan Edain says:
I do not understand the lines: window.SyntaxHighlighter.config.clipboardSwf =...I do not understand the lines:
Does this mean that you expect a locally installed copy of Confluence?
May 25, 2009
raptors says:
As described in the Atlassian Maven Plugin Development Kit for Maven 2, these va...As described in the Atlassian Maven Plugin Development Kit for Maven 2, these values are used for the automatic installation of your plugin. As you have hopefully discovered by now (since May 20), running
gives you a jar file that you can install on your Confluence server manually, and I get no errors about settings.xml even if the server, user and password information specified there is wrong at the moment.
Oct 01
Betsy Walker says:
Just an FYI... I'm running behind a proxy server, and I needed to both add the &...Just an FYI... I'm running behind a proxy server, and I needed to both add the <proxy> section as noted above, AND change the repository URLS from https:// to http:// in order to avoid errors like 'Error transferring file: Connection timed out: connect' and 'Unable to find resource xxxx in repository central'.
Oct 14
Steve Kipping says:
To get this to work I had to add the proxy declaration too. However it wouldn't ...To get this to work I had to add the proxy declaration too. However it wouldn't work if I remove the s from the https URLs.
To get it to work I had to set the protocol to https in the proxy section and it's now downloading a treat :-)
<proxies>
<proxy>
<active>true</active>
<protocol>https</protocol>
<username>myname</username>
<password>nypassword</password>
<host>proxyip</host>
<port>proxyport</port>
</proxy>
</proxies>