Skip to content

Commit

Permalink
infra: use slugify-value (#1016)
Browse files Browse the repository at this point in the history
  • Loading branch information
Shinigami92 authored Mar 6, 2024
1 parent 2f7c495 commit d5f279a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 13 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/coverage-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@ jobs:

steps:
- name: Slugify variables
uses: rlespinasse/github-slug-action@102b1a064a9b145e56556e22b18b19c624538d94 # v4.4.1
uses: rlespinasse/slugify-value@a4879db1eb3db9bbee01dca36f98a8236c2b8239 # v1.4.0
with:
key: HEAD_REF
value: ${{ github.head_ref }}

- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
Expand All @@ -25,7 +28,7 @@ jobs:
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
run-id: ${{ github.event.workflow_run.id }}
name: coverage-${{ env.GITHUB_HEAD_REF_SLUG }}
name: coverage-${{ env.HEAD_REF_SLUG }}
path: coverage

- name: Download main Artifacts
Expand Down
17 changes: 6 additions & 11 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ jobs:

steps:
- name: Slugify variables
uses: rlespinasse/github-slug-action@102b1a064a9b145e56556e22b18b19c624538d94 # v4.4.1
uses: rlespinasse/slugify-value@a4879db1eb3db9bbee01dca36f98a8236c2b8239 # v1.4.0
with:
key: BRANCH
value: ${{ matrix.branch }}

- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
Expand All @@ -41,18 +44,10 @@ jobs:
run: pnpm run build

- name: Test
run: pnpm vitest --coverage
run: pnpm run test:coverage

- name: Upload Coverage
if: ${{ matrix.branch != 'main' }}
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
with:
name: coverage-${{ env.GITHUB_HEAD_REF_SLUG }}
path: coverage

- name: Upload main Coverage
if: ${{ matrix.branch == 'main' }}
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
with:
name: coverage-main
name: coverage-${{ env.BRANCH_SLUG }}
path: coverage

0 comments on commit d5f279a

Please sign in to comment.