-
Notifications
You must be signed in to change notification settings - Fork 2
48 lines (47 loc) · 1.18 KB
/
ci.yml
File metadata and controls
48 lines (47 loc) · 1.18 KB
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
---
name: CI
on:
push:
tags: ['v*']
branches: [main]
pull_request:
branches: ['**']
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ruby: [2.5, 2.6, 2.7, 3.0, jruby-9.2.19, truffleruby-21.1.0]
bundler: [default]
include:
- ruby: '2.3'
bundler: '1'
- ruby: '2.4'
bundler: '1'
steps:
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler: ${{ matrix.bundler }}
bundler-cache: true
- run: bundle exec rubocop
if: matrix.ruby == '2.7'
- run: bundle exec rspec --format doc
- uses: codecov/codecov-action@v3
if: matrix.ruby == '2.7'
with:
files: coverage/coverage.xml
- run: bin/yardoc --fail-on-warning
if: matrix.ruby == '2.7'
- run: bin/check-version
release:
needs: test
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: dawidd6/action-publish-gem@v1
with:
api_key: ${{secrets.RUBYGEMS_API_KEY}}