Skip to content

testing check format #5

testing check format

testing check format #5

Workflow file for this run

name: Format
on: [push]
jobs:
format:
runs-on: ubuntu-latest
permissions:
# Give the default GITHUB_TOKEN write permission to commit and push the
# added or changed files to the repository.
contents: write
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- uses: actions/setup-node@v4
with:
node-version: "20"
- run: npm ci
- name: Check Formatting
run: npm run format:check
- name: Fail if not formatted correctly
run: |
if [ $? -eq 0 ]; then
echo "Files are formatted correctly."
else
echo "Files are not formatted correctly. Please run 'prettier' to format your code."
exit 1
fi