Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run Codecov as a separate workflow #136

Merged
merged 1 commit into from
May 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: autocorrect

on:
pull_request:

push:
branches:
- "master"

jobs:
codecov:
runs-on: ubuntu-latest

strategy:
matrix:
ruby: [3.0]

steps:
- uses: actions/checkout@v3
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- name: Cache dependencies
uses: actions/cache@v3
with:
path: vendor/bundle
key: ${{ runner.os }}-${{ matrix.ruby }}-gems-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-${{ matrix.ruby }}-gems-
- name: Install dependencies
run: |
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
- name: Run tests
run: bundle exec rake test
- name: Upload coverage
uses: codecov/codecov-action@v4
with:
files: coverage/coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}
4 changes: 0 additions & 4 deletions .github/workflows/build.yml → .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@ jobs:
bundle install --jobs 4 --retry 3
- name: Run tests
run: bundle exec rake test
- name: Upload coverage
uses: codecov/codecov-action@v3
with:
files: coverage/coverage.xml

lint:
needs: test
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ Gemfile.lock
.bundle
*.gem
*.gemfile.lock
/.vscode
/coverage
/pkg
/tags
Expand Down
Loading