name: Check the source code
on:
  push:
    branches: [master]
  pull_request:
    branches: [master]
jobs:
  check_source_code:
    name: Check the source code
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - uses: actions/setup-node@v4
        with:
          node-version: 22
          cache: 'yarn'

      - name: Install dependencies
        run: yarn install

      - name: Check formatting
        run: yarn format:check

      - name: Lint
        run: yarn lint
