Skip to content

Commit

Permalink
PR CI에서 전체 MDX 파일 검사
Browse files Browse the repository at this point in the history
  • Loading branch information
XiNiHa committed Apr 17, 2024
1 parent 73c5d21 commit 35c6a79
Showing 1 changed file with 2 additions and 31 deletions.
33 changes: 2 additions & 31 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,38 +6,9 @@ on:
- main

jobs:
changed_files:
runs-on: ubuntu-latest
name: Lint changed MDX files
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: pnpm/action-setup@v3
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
- run: pnpm install

- name: Get all changed MDX files
id: changed-mdx-files
uses: tj-actions/changed-files@v42
with:
files: |
**.mdx
- name: Lint all changed MDX files
if: steps.changed-mdx-files.outputs.any_changed == 'true'
env:
ALL_CHANGED_FILES: ${{ steps.changed-mdx-files.outputs.all_changed_files }}
run: |
pnpm eslint $ALL_CHANGED_FILES
code:
runs-on: ubuntu-latest
name: Lint code
name: Lint code and MDX files
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3
Expand All @@ -49,4 +20,4 @@ jobs:
cache: 'pnpm'
- run: pnpm install
- run: pnpm typecheck
- run: pnpm eslint . --ignore-pattern '**/*.mdx'
- run: pnpm eslint .

0 comments on commit 35c6a79

Please sign in to comment.