Skip to content

Commit

Permalink
Only upload if Ruby 3.3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
kigster committed Jun 30, 2024
1 parent aa4add4 commit 768d459
Showing 1 changed file with 16 additions and 9 deletions.
25 changes: 16 additions & 9 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Ruby

on: [push,pull_request]
on: [pull_request, workflow_dispatch]

jobs:
build:
Expand All @@ -20,18 +20,25 @@ jobs:
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler-cache: true # runs 'bun
bundler-cache: true # runs 'bun

- name: Run Specs
run: make test-all

- name: Rubocop
run: bundle exec rubocop --parallel

- uses: codecov/codecov-action@v4
with:
fail_ci_if_error: false # optional (default = false)
files: coverage/coverage.xml
flags: rspecs # optional
token: ${{ secrets.CODECOV_TOKEN }} # required
verbose: true # optional (default = false)`
- name: Upload to Codecov
run: |
if [[ $(ruby -e 'puts RUBY_VERSION') == '3.3.1' ]]; then
curl -Os https://uploader.codecov.io/latest/linux/codecov
chmod +x codecov
./codecov
fi
# - uses: codecov/codecov-action@v4
# with:
# fail_ci_if_error: false # optional (default = false)
# flags: rspecs # optional
# token: ${{ secrets.CODECOV_TOKEN }} # required
# verbose: true # optional (default = false)`

0 comments on commit 768d459

Please sign in to comment.