Skip to content

update format.yml

update format.yml #8

Workflow file for this run

name: Format
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: write
workflows: write

Check failure on line 10 in .github/workflows/format.yml

View workflow run for this annotation

GitHub Actions / Format

Invalid workflow file

The workflow is not valid. .github/workflows/format.yml (Line: 10, Col: 5): Unexpected value 'workflows'
jobs:
format:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "22.x"
- name: Install dependencies
run: npm ci
- name: Run Prettier
run: npm run format
- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "Apply formatting changes"
branch: ${{ github.head_ref }}