Skip to content

Commit 33d0c9f

Browse files
Use Github release automation (#2500)
Co-authored-by: M.P. Korstanje <[email protected]>
1 parent 1ccc09f commit 33d0c9f

File tree

4 files changed

+55
-11
lines changed

4 files changed

+55
-11
lines changed

.github/workflows/release-github.yml

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
name: Release on GitHub
2+
3+
on:
4+
push:
5+
branches: [release/*]
6+
7+
jobs:
8+
pre-release-check:
9+
uses: cucumber/.github/.github/workflows/prerelease-checks.yml@main

.github/workflows/release-java.yml

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Release maven package
2+
3+
on:
4+
push:
5+
branches: [release/*]
6+
7+
jobs:
8+
pre-release-check:
9+
uses: cucumber/.github/.github/workflows/prerelease-checks.yml@main
10+
11+
test-java:
12+
uses: ./.github/workflows/test-java.yml
13+
14+
publish-mvn:
15+
name: Publish Maven Package
16+
needs: [pre-release-check, test-java]
17+
runs-on: ubuntu-latest
18+
environment: Release
19+
20+
steps:
21+
- uses: actions/checkout@v2
22+
23+
- uses: actions/setup-java@v2
24+
with:
25+
distribution: "temurin"
26+
java-version: "11"
27+
cache: "maven"
28+
29+
- uses: cucumber/[email protected]
30+
with:
31+
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
32+
gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }}
33+
nexus-username: cukebot
34+
nexus-password: ${{ secrets.SONATYPE_PASSWORD }}

.github/workflows/build.yml renamed to .github/workflows/test-java.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
name: Cucumber CI
1+
name: Test java
22

33
on:
44
pull_request:
55
branches:
66
- '**'
7+
workflow_call:
78
push:
89
branches:
910
- main

RELEASING.md

+10-10
Original file line numberDiff line numberDiff line change
@@ -43,28 +43,26 @@ Check if branch name and version are as expected. To change version run:
4343
mvn versions:set -DnewVersion=X.Y.Z-SNAPSHOT
4444
```
4545

46-
## Secrets ##
47-
48-
Secrets are required to make releases. Members of the core team can install
49-
keybase and join the `cucumberbdd` team to access these secrets.
50-
51-
During the release process, secrets are fetched from keybase and used to sign
52-
and upload the maven artifacts.
53-
5446
## Make the release ##
5547

56-
Check if branch name and version are as expected:
48+
Only people with permission to push to `release/*` branches can make releases.
49+
50+
1. Check if branch name and version are as expected:
5751

5852
```
5953
make version
6054
```
6155

62-
Do the release:
56+
2. Do the release:
6357

6458
```
6559
make release
6660
```
6761

62+
3. Wait until the `release-*` workflows have passed for the new release branch:
63+
* [![Release maven package](https://github.com/cucumber/cucumber-jvm/actions/workflows/release-java.yml/badge.svg)](https://github.com/cucumber/cucumber-jvm/actions/workflows/release-java.yml)
64+
* [![Release on GitHub](https://github.com/cucumber/cucumber-jvm/actions/workflows/release-github.yml/badge.svg)](https://github.com/cucumber/cucumber-jvm/actions/workflows/release-github.yml)
65+
6866
## Last bits ##
6967

7068
Update the cucumber-jvm version in the documentation project:
@@ -74,3 +72,5 @@ Update the cucumber-jvm version in the documentation project:
7472
The cucumber-jvm version for the docs is specified in the docs [versions.yaml](https://github.com/cucumber/docs.cucumber.io/blob/master/data/versions.yaml)
7573

7674
All done! Hurray!
75+
76+
[changelog]: https://github.com/cucumber/changelog#installation

0 commit comments

Comments
 (0)