From 18536bc7ed29e33238ff5f1b5d9d51f00b1a4695 Mon Sep 17 00:00:00 2001 From: Jean Luis Urena Date: Tue, 9 Jul 2024 17:41:22 -0400 Subject: [PATCH] [ISSUE-68] Fix github ci for cross-repos --- .github/workflows/ruby.yml | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index da77e42..e4ef754 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -5,18 +5,18 @@ # This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake # For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby -name: Code Coverage - -on: [push, workflow_dispatch, pull_request] - +name: Code Guard +on: + pull_request: + workflow_dispatch: +concurrency: + group: ${{ github.ref }}-${{ github.workflow }} + cancel-in-progress: true permissions: - contents: read - + checks: write + contents: write jobs: test: - permissions: - checks: write - contents: write runs-on: ubuntu-20.04 strategy: matrix: @@ -34,11 +34,17 @@ jobs: DEBUG: true - name: Run tests run: bundle exec rake - - name: Code Coverage - uses: joshmfrankel/simplecov-check-action@main + - if: matrix.rails-version == "7.1" + uses: joshmfrankel/simplecov-check-action@1.0.0 with: check_job_name: Code Coverage - github_token: ${{ secrets.GITHUB_TOKEN }} minimum_suite_coverage: 100 + github_token: ${{ secrets.GITHUB_TOKEN }} + lint: + needs: [test] + runs-on: ubuntu-20.04 + steps: - name: Lint uses: standardrb/standard-ruby-action@v1 + with: + ruby-version: "3.0"