Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
mrsasuu committed Dec 11, 2024
1 parent 3eeacf3 commit 7b8556b
Showing 1 changed file with 8 additions and 19 deletions.
27 changes: 8 additions & 19 deletions .github/workflows/lint-format-check.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Lint and Format Changed Files
name: Lint and Format Check

on:
pull_request:
Expand All @@ -25,21 +25,10 @@ jobs:
- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Get changed files
id: changed-files
run: |
git fetch origin ${{ github.base_ref }}
git diff --name-only origin/${{ github.base_ref }} > changed-files.txt
echo "CHANGED_FILES=$(cat changed-files.txt | grep -E '\.js$|\.ts$')" >> $GITHUB_ENV
- name: Run lint on changed files
if: env.CHANGED_FILES
run: |
echo "Linting files..."
yarn eslint $CHANGED_FILES
- name: Check formatting on changed files
if: env.CHANGED_FILES
run: |
echo "Checking formatting..."
yarn prettier --check $CHANGED_FILES
- name: Run lint check
run: yarn lint
continue-on-error: false

- name: Check formatting
run: yarn prettier --check .
continue-on-error: false

0 comments on commit 7b8556b

Please sign in to comment.