# 当有人提交 PR 时自动进行代码检查

name: FORMAT REVIEW

on:
  pull_request:
    branches:
      - main

jobs:
  format:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v4

      - name: Setup Node.js environment
        uses: actions/setup-node@v3
        with:
          node-version: 20.x

      - name: Install dependencies
        run: npm install

      - name: Run code review
        run: |
          npm run lint
