mirror of
https://github.com/danbulant/oxc
synced 2026-05-21 13:18:59 +00:00
[](https://renovatebot.com) This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [codecov/codecov-action](https://togithub.com/codecov/codecov-action) | action | major | `v3` -> `v4` | --- ### Release Notes <details> <summary>codecov/codecov-action (codecov/codecov-action)</summary> ### [`v4`](https://togithub.com/codecov/codecov-action/compare/v3...v4) [Compare Source](https://togithub.com/codecov/codecov-action/compare/v3...v4) </details> --- ### Configuration 📅 **Schedule**: Branch creation - "before 8am on monday" in timezone Asia/Shanghai, Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/oxc-project/oxc). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4xNzAuMCIsInVwZGF0ZWRJblZlciI6IjM3LjE3MC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
74 lines
1.8 KiB
YAML
74 lines
1.8 KiB
YAML
# Run cargo-llvm-cov and upload to codecov.io
|
|
|
|
name: Code Coverage
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
push:
|
|
branches:
|
|
- main
|
|
paths:
|
|
- '**.rs'
|
|
- '.github/workflows/codecov.yml'
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: ${{ github.ref_name != 'main' }}
|
|
|
|
jobs:
|
|
coverage:
|
|
name: Code Coverage
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Clone submodules
|
|
uses: ./.github/actions/clone-submodules
|
|
|
|
- name: Install Rust Toolchain
|
|
uses: ./.github/actions/rustup
|
|
|
|
- name: Install cargo-llvm-cov
|
|
uses: taiki-e/install-action@v2
|
|
with:
|
|
tool: cargo-llvm-cov
|
|
|
|
- name: Install llvm-tools-preview for llvm-cov
|
|
run: rustup component add llvm-tools-preview
|
|
|
|
- name: Run
|
|
run: cargo codecov --lcov --output-path lcov.info
|
|
|
|
- name: Upload Artifact
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: codecov
|
|
path: lcov.info
|
|
|
|
# codecov often fails, use another workflow for retry
|
|
upload-codecov:
|
|
name: Upload coverage file
|
|
runs-on: ubuntu-latest
|
|
needs: coverage
|
|
# Check if the event is not triggered by a fork by checking whether CODECOV_TOKEN is set
|
|
env:
|
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
|
steps:
|
|
- name: Checkout
|
|
if: env.CODECOV_TOKEN
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Download coverage file
|
|
if: env.CODECOV_TOKEN
|
|
uses: actions/download-artifact@v4
|
|
with:
|
|
name: codecov
|
|
|
|
- name: Upload to codecov.io
|
|
if: env.CODECOV_TOKEN
|
|
uses: codecov/codecov-action@v4
|
|
with:
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
fail_ci_if_error: true
|
|
files: lcov.info
|