Skip to content

Commit ab731a6

Browse files
committed
[Build] Add release guide
1 parent 862316b commit ab731a6

File tree

1 file changed

+95
-0
lines changed

1 file changed

+95
-0
lines changed

RELEASING.md

Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
Releasing
2+
=========
3+
4+
The process of deploying to maven central has been automated based on
5+
the [Complete guide to continuous deployment to maven central from Travis CI](http://www.debonair.io/post/maven-cd/)
6+
and will be executed whenever a non-snapshot version is committed.
7+
8+
## Check [![Build Status](https://travis-ci.org/cucumber/cucumber-jvm-scala.svg?branch=master)](https://travis-ci.org/cucumber/cucumber-jvm-scala) ##
9+
10+
Is the build passing?
11+
12+
```
13+
git checkout master
14+
```
15+
16+
Also check if you can upgrade any dependencies:
17+
18+
```
19+
mvn versions:display-dependency-updates
20+
```
21+
22+
## Make the release ##
23+
24+
Now release everything:
25+
26+
```
27+
mvn release:clean release:prepare -DautoVersionSubmodules=true -Darguments="-DskipTests=true"
28+
```
29+
30+
Travis will now deploy everything.
31+
32+
It is preferable to use the automated deployment process over the manual process. However should travis.ci fail or should the
33+
need arise to setup another continuous integration system the [Manual deployment](#manual-deployment) section
34+
describes how this works.
35+
36+
# Manual deployment #
37+
38+
It is preferable to use the automated deployment process over the manual process.
39+
40+
The deployment process of `cucumber-jvm` is based on
41+
[Deploying to OSSRH with Apache Maven](http://central.sonatype.org/pages/apache-maven.html#deploying-to-ossrh-with-apache-maven-introduction).
42+
This process is nearly identical for both snapshot deployments and releases. Whether a snapshot
43+
deployment or release is executed is determined by the version number.
44+
45+
To make a release you must have the `[email protected]` GPG private key imported in gpg2.
46+
47+
```
48+
gpg --import devs-cucumber.io.key
49+
```
50+
51+
Additionally upload privileges to the Sonatype repositories are required. See the
52+
[OSSRH Guide](http://central.sonatype.org/pages/ossrh-guide.html) for instructions. Then an
53+
administrator will have to grant you access to the cucumber repository.
54+
55+
Finally both your OSSRH credentials and private key must be setup in your `~/.m2/settings.xml` -
56+
for example:
57+
58+
```
59+
<settings>
60+
<servers>
61+
<server>
62+
<id>ossrh</id>
63+
<username>sonatype-user-name</username>
64+
<password>sonatype-password</password>
65+
</server>
66+
</servers>
67+
<profiles>
68+
<profile>
69+
<id>ossrh</id>
70+
<activation>
71+
<activeByDefault>true</activeByDefault>
72+
</activation>
73+
<properties>
74+
<gpg.executable>gpg2</gpg.executable>
75+
<gpg.useagent>true</gpg.useagent>
76+
</properties>
77+
</profile>
78+
<profile>
79+
<id>sign-with-cucumber-key</id>
80+
<properties>
81+
<gpg.keyname>dev-cucumber.io-key-id</gpg.keyname>
82+
</properties>
83+
</profile>
84+
</profiles>
85+
</settings>
86+
```
87+
88+
89+
# Deploy the release #
90+
91+
```
92+
mvn release:perform -Psign-source-javadoc -DskipTests=true
93+
```
94+
95+
Go into [Nexus](https://oss.sonatype.org/) and inspect, close and release the staging repository.

0 commit comments

Comments
 (0)