name: Pull Request

on: pull_request

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code & submodules
        uses: actions/checkout@v3
        with:
          submodules: true

      - name: Setup pnpm
        uses: pnpm/action-setup@v2.2.1
        with:
          version: latest

      - name: Setup NodeJS
        uses: actions/setup-node@v3
        with:
          node-version: 17

      - name: Install Dependencies
        run: pnpm install

      - name: Lint & Format
        run: pnpm format

      - name: Build Site
        run: pnpm build
