-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
55 lines (50 loc) · 1.34 KB
/
release.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Release RubyGems
on:
push:
branches:
- release/*
jobs:
pre-release-check:
name: Perform checks before releasing
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: |
git fetch --quiet origin main
git merge-base --is-ancestor HEAD origin/main
tests:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
ruby: ["2.7", "3.0", "3.1", "3.2"]
include:
- os: ubuntu-latest
ruby: jruby-9.4
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/test-ruby
with:
ruby-version: ${{ matrix.ruby }}
publish-rubygem:
name: Publish Ruby Gem
needs: [pre-release-check, tests]
runs-on: ubuntu-latest
environment: Release
steps:
- uses: actions/checkout@v4
- uses: cucumber/[email protected]
with:
rubygems_api_key: ${{ secrets.RUBYGEMS_API_KEY }}
create-github-release:
name: Create GitHub Release and Git tag
needs: publish-rubygem
runs-on: ubuntu-latest
environment: Release
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- uses: cucumber/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}