.github/workflows/ci.yml
name: ci
on:
push:
branches:
- "*"
pull_request:
branches:
- "*"
schedule:
- cron: 0 2 * * 3,6
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
strategy:
fail-fast: false
matrix:
ruby: ['3.3', '3.2', '3.1', '3.0']
name: Ruby ${{ matrix.ruby }}
steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler: latest
bundler-cache: true
cache-version: 1
- name: Code Climate setup test reporter
run: |
curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
chmod +x ./cc-test-reporter
./cc-test-reporter before-build
- name: Run default task
run: |
bundle exec rake
- name: Code Climate publish test coverage
run: |
./cc-test-reporter after-build