Skip to content

Latest commit

 

History

History
121 lines (86 loc) · 3.54 KB

RELEASING.md

File metadata and controls

121 lines (86 loc) · 3.54 KB

Releasing

The process of deploying to maven central has been automated based on the Complete guide to continuous deployment to maven central from Travis CI and will be executed whenever a non-snapshot version is committed.

Check Build Status

Is the build passing?

git checkout master

Also check if you can upgrade any dependencies:

mvn versions:display-dependency-updates

Prepare for release

Replace version numbers in:

  • CHANGELOG.md

Then run (replace X.Y.Z below with the next release number):

git commit -am "Prepare for release X.Y.Z"

Make the release

Now release everything:

mvn release:clean release:prepare -DautoVersionSubmodules=true -Darguments="-DskipTests=true"  

Travis will now deploy everything. Once travis is done go into Nexus and inspect, close and release the staging repository.

It is preferable to use the automated deployment process over the manual process. However should travis.ci fail or should the need arise to setup another continuous integration system the Manual deployment section describes how this works.

Last bits

Wait for the release to show up on maven central. Then update the dependency in example projects:

Update the cucumber-jvm version in the documentation project:

The cucumber-jvm version for the docs is specified in the docs versions.yaml

All done! Hurray!

Manual deployment

It is preferable to use the automated deployment process over the manual process.

The deployment process of cucumber-jvm is based on Deploying to OSSRH with Apache Maven. This process is nearly identical for both snapshot deployments and releases. Whether a snapshot deployment or release is executed is determined by the version number.

To make a release you must have the devs@cucumber.io GPG private key imported in gpg2.

gpg --import devs-cucumber.io.key

Additionally upload privileges to the Sonatype repositories are required. See the OSSRH Guide for instructions. Then an administrator will have to grant you access to the cucumber repository.

Finally both your OSSRH credentials and private key must be setup in your ~/.m2/settings.xml - for example:

<settings>
    <servers>
        <server>
            <id>ossrh</id>
            <username>sonatype-user-name</username>
            <password>sonatype-password</password>
        </server>
    </servers>
    <profiles>
        <profile>
            <id>ossrh</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <properties>
                <gpg.executable>gpg2</gpg.executable>
                <gpg.useagent>true</gpg.useagent>
            </properties>
        </profile>
        <profile>
            <id>sign-with-cucumber-key</id>
            <properties>
                <gpg.keyname>dev-cucumber.io-key-id</gpg.keyname>
            </properties>
        </profile>
    </profiles>
</settings>

Deploy the release

mvn release:perform -Psign-source-javadoc -DskipTests=true