datasette/.github/workflows/prettier.yml
Alex Garcia 063eeae83d
Slim down CI runs per commit (#2911)
- Only run push-triggered workflows on main; PRs are covered by
  pull_request, so branch commits no longer run everything twice
- Test SQLite versions: single job, Python 3.13 + SQLite 3.25
- Fold coverage into the Python 3.14 test job (including serial
  tests) and remove test-coverage.yml; bump codecov-action to v5
- Cancel superseded in-progress runs on pull requests
- Prettier now also runs on pull requests

Claude-Session: https://claude.ai/code/session_012G7fa8HqJy9AkSjkocetAz
2026-09-15 08:51:24 -07:00

34 lines
793 B
YAML

name: Check JavaScript for conformance with Prettier
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
permissions:
contents: read
jobs:
prettier:
runs-on: ubuntu-latest
steps:
- name: Check out repo
uses: actions/checkout@v7
- uses: actions/cache@v6
name: Configure npm caching
with:
path: ~/.npm
key: ${{ runner.OS }}-npm-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.OS }}-npm-
- name: Install dependencies
run: npm ci
- name: Run prettier
run: |-
npm run prettier -- --check