jiminoc/goose — pull request #67 by matth (2012-11-27 14:34:08+00:00)
Title: Sonatype hosting

# Add sontaype repo support

Hi there, I have added sontatype nexus support repo and uploaded the project to their OSS Maven repo. Please find below a summary of changes and some details on how to upload to Nexus:

## Goose in a public Maven repo

https://oss.sonatype.org/content/repositories/releases/com/gravity/goose/

## Changes in this pull request (all to pom.xml)

* Update scala-maven-plugin, now has better support for Nexus
* Add some extra details suggested by Nexus, inherit from Nexus OSS parent
* Replace javadoc plugin execution for scaldoc plugin execution (it actually generates a javadoc.jar now!)

## Suggested improvements

* Add developer info to pom

## How I deployed it

I got a Maven repo setup on Nexus, https://issues.sonatype.org/browse/OSSRH-4770 it would be great for you guys to be able to deploy releases to it!

Setting up Maven for an automated release was a bit painful, here's what I did ...

### Ensure you ~/.m2/settings.xml has the following

org.sonatype.plugins

sonatype-nexus-snapshots
YOUR_SONATYPE_USERNAME
YOUR_SONATYPE_PASSWORD

sonatype-nexus-staging
YOUR_SONATYPE_USERNAME
YOUR_SONATYPE_PASSWORD

### Ensure you have gpg installed and a key pair generate and published to a keyserver

* `brew install gpg` - If your on a Mac
* http://www.madboa.com/geek/gpg-quickstart/ - Ensure to do the keyserver part, I used keyserver.ubuntu.com

### Add a snapshot for current release

* Ensure current version in pom.xml ends with -SNAPSHOT
* `mvn clean deploy`

### Stage a release

* `mvn release:clean`
* `mvn release:prepare`
* `mvn release:perform`

### Release it!

Via the nexus plugin ...

* `mvn nexus:staging-list`
* `mvn nexus:staging-close`
* `mvn nexus:staging-prmote`

Or the web interface ...

https://oss.sonatype.org/index.html

### More info / resources

* https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide
* http://www.sonatype.com/books/nexus-book/reference/staging-sect-managing-plugin.html