aldaris / docbook-linktester

Tests external links and olinks in DocBook documentation for validity
3 stars 1 forks source link

Deploy to Maven central? #1

Closed nawroth closed 11 years ago

nawroth commented 11 years ago

This looks like a very useful tool! However, I won't be able to put it into production use until it hits Maven central. Any reason it's not deployed there as well?

aldaris commented 11 years ago

It's not there yet, but should be available under: http://maven.forgerock.org/repo/releases I'll look into how to get it to central, but frankly it could take some time for me to finish it up :p

nawroth commented 11 years ago

The 1.0.0 release is there: http://maven.forgerock.org/repo/releases/org/forgerock/maven/plugins/linktester-maven-plugin/1.0.0/

I'd be happy to help you start deploying releases to Maven central. It's not hard at all. I'm in charge of that in a quite big project (neo4j.org), and also helped one other project (rrd4j) get there.

Basically:

  1. get an account with sonatype, tell them you want in, see: https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide
  2. verify the config vs requirements (I've done this a lot ...)
  3. create and publish signing key
  4. deploy to sonatype, release to central
aldaris commented 11 years ago

Looks like the next blocking problem will be to sign the artifacts using PGP, but unfortunately I don't have them with me, so this have to wait at least until tuesday. In the meanwhile: the good news is that Sonatype has approved my JIRA request, so I should be able to deploy new artifacts once the signing is configured.

nawroth commented 11 years ago

Wow, this is moving fast, awesome! I use to sign the artifacts by having the gpg-agent running, and sign some dummy file before the build to let the gpg-agent cache the password of the key. Config I use looks like so: https://github.com/neo4j/parents/blob/master/pom.xml#L198

Also, I think they want you to use their parent pom, this way: <parent> <groupId>org.sonatype.oss</groupId> <artifactId>oss-parent</artifactId> <version>7</version> </parent>

If you get into trouble when switching on the sonatype-oss-release profile, you can override parts of it by declaring a profile by the same name, here's what I've been doing: https://github.com/neo4j/parents/blob/master/pom.xml#L984

aldaris commented 11 years ago

For now I haven't really decided between using the parent and just simply putting in the distributionmanagement elements into my pom. If I'm not mistaken their distributionManagement is outside of the profile, so that would mean that every build would try to deploy the artifact to sonatype, or? If yes, then I would probably change that to be part of a profile instead..

nawroth commented 11 years ago

You're right. It would try to deploy to sonatype unless you override it somehow. I assume they should be fine with you adding it in the profile instead. In my case, we're setting deployment repo from the command line anyhow.

aldaris commented 11 years ago

For starters: https://oss.sonatype.org/content/repositories/snapshots/org/forgerock/maven/plugins/linktester-maven-plugin/1.1.0-SNAPSHOT/ I will look into release 1.1.0 (probably won't change anything in functionality), then try to push it out to central.

nawroth commented 11 years ago

Really great to see that it works out well so far!

aldaris commented 11 years ago

FYI 1.1.0 is now in the staging section, I'm just waiting for Sonatype to enable Central sync for me. ;)

aldaris commented 11 years ago

The artifact is now synced to Maven central, you should be able to access it at: http://search.maven.org/#artifactdetails%7Corg.forgerock.maven.plugins%7Clinktester-maven-plugin%7C1.1.0%7Cmaven-plugin Closing my very first ticket.

nawroth commented 11 years ago

Thanks, @aldaris this was a truly awesome way to respond to my request! :-)

I hope I'll be able to contribute to the project somehow.