[feat] update git workflows #3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Lint Code Quality | |
| on: | |
| pull_request: | |
| branches: [main, develop] | |
| push: | |
| branches: [main, develop] | |
| workflow_dispatch: | |
| workflow_call: | |
| jobs: | |
| eslint: | |
| name: ESLint Check | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| checks: write | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: "20" | |
| cache: "npm" | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Run ESLint with Reviewdog | |
| uses: reviewdog/action-eslint@v1 | |
| with: | |
| reporter: github-pr-review | |
| eslint_flags: "." | |
| fail_on_error: true | |
| filter_mode: nofilter | |
| - name: Success message | |
| if: success() | |
| run: echo "✅ All linting checks passed!" |