name: rqrcode_core

on:
  push:
    branches:
      - main
      - release
  pull_request: # Runs on any PR regardless of target branch
  workflow_dispatch:

jobs:
  Build:
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, macos-latest]
        ruby: ["3.2", "3.3", "3.4", "4.0"]
    runs-on: ${{ matrix.os }}
    steps:
      - uses: actions/checkout@v3
      - uses: ruby/setup-ruby@v1
        with:
          ruby-version: ${{ matrix.ruby }}
          bundler-cache: true # runs 'bundle install' and caches installed gems automatically
      - name: Run Tests
        run: bundle exec rake test
      - name: StandardRB Check
        run: bundle exec standardrb --format progress
