Closed cjmyers closed 8 years ago
Here's the Central Repository guide: https://maven.apache.org/guides/mini/guide-central-repository-upload.html I understand that cutting a release following these guidelines is pretty simple, though I haven't done it myself yet.
Thanks, -Jake
Begin forwarded message:
From: Neil Swainston neil.swainston@googlemail.com Date: 18 October 2015 at 08:52:29 BST To: Ernst Oberortner e.oberortner@gmail.com Cc: Zach Zundel zach.zundel@utah.edu, u0030884 myers@ece.utah.edu, libSBOL-team libsbol-team@googlegroups.com, Raik Grünberg raik.gruenberg@gmail.com, "James Mclaughlin (PGR)" j.a.mclaughlin@newcastle.ac.uk Subject: Re: HOWTO on clone, compile, and integrate libSBOLj v2.0
Hi Ernst,
I agree with Zach - the Central Maven Repository is the way to go. Think actually, when you sort it, users will only have to add the following to their pom.xml file, as the Central Repository is accessed by default:
I recently did this for another project and it wasn’t too arduous. I enclose the pom.xml as an example.
The key is specifying two repositories: one for snapshots, one for full releases:
The next was adding two plugins, the first for security reasons, signing and verifying the distributions, and the second for submitting to the repository:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.6.3</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>true</autoReleaseAfterClose>
</configuration>
</plugin>
The gpg plugin (first one) requires that gpg is installed locally: https://www.gnupg.org/
You’ll then need an account with Sonatype, and a “ticket” for the libSBOLj project (see Initial Setup here: http://central.sonatype.org/pages/ossrh-guide.html#releasing-to-central). Probably need an organisation SBOL account somehow, rather than a personal Ernst, Zach or Neil one. This is just to confirm to users that the distribution is trustworthy.
Finally, think you’ll need an update to your settings.xml file in your local .mvn directory to include the Sonatype account username and password (see enclosed file).
Then, I think it’s...
mvn clean deploy
…and you’re done.
As always, life is never that straightforward. Let me know if / when you have problems.
Cheers,
Neil.
Neil Swainston, PhD Senior Experimental Officer
Centre for Synthetic Biology of Fine and Speciality Chemicals (SYNBIOCHEM) Manchester Institute of Biotechnology University of Manchester Manchester M1 7DN United Kingdom
On 18 Oct 2015, at 01:48, Ernst Oberortner e.oberortner@gmail.com wrote:
That would be ideal IMO.
for version 1, we had the following solution: In the pom.xml file of your Java project, you had to specify: 1) a sonatype repository
Done.
This should not be done though until we are at stable 2.0. Here is what may be involved.
I recently did this for another project and it wasn’t too arduous. I enclose the pom.xml as an example.
The key is specifying two repositories: one for snapshots, one for full releases:
The next was adding two plugins, the first for security reasons, signing and verifying the distributions, and the second for submitting to the repository:
The gpg plugin (first one) requires that gpg is installed locally: https://www.gnupg.org/
You’ll then need an account with Sonatype, and a “ticket” for the libSBOLj project (see Initial Setup here: http://central.sonatype.org/pages/ossrh-guide.html#releasing-to-central). Probably need an organisation SBOL account somehow, rather than a personal Ernst, Zach or Neil one. This is just to confirm to users that the distribution is trustworthy.
Finally, think you’ll need an update to your settings.xml file in your local .mvn directory to include the Sonatype account username and password (see enclosed file).
Then, I think it’s...
mvn clean deploy
…and you’re done.