Updates based on feedback #5
Workflow file for this run
This file contains 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: Auto Fix Code Issues | |
on: | |
pull_request: | |
types: [opened, synchronize] | |
jobs: | |
autofix: | |
name: Auto-fix Code Issues | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
pull-requests: write | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.head_ref }} | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: "20" | |
cache: "npm" | |
- name: Install dependencies | |
run: npm ci | |
- name: Run Prettier | |
run: npx prettier --write . | |
- name: Run ESLint fix | |
run: npx eslint . --fix --ext .js,.jsx,.ts,.tsx | |
- name: Commit changes | |
uses: stefanzweifel/git-auto-commit-action@v5 | |
with: | |
commit_message: "style: auto-fix code formatting and linting issues" | |
branch: ${{ github.head_ref }} |