name: 'Format Code' on: push: branches: - main jobs: format: runs-on: ubuntu-latest steps: - name: Check out code using Git uses: actions/checkout@v2 with: ref: ${{ github.head_ref }} - name: Install NPM Dependencies run: pnpm install env: CI: true - name: Format code run: pnpm run format - name: Commit changes uses: stefanzweifel/git-auto-commit-action@v4 with: commit_message: '[ci] format' branch: ${{ github.head_ref }}