| 1 | name: CI |
| 2 | |
| 3 | on: |
| 4 | pull_request: |
| 5 | push: |
| 6 | |
| 7 | permissions: |
| 8 | contents: read |
| 9 | |
| 10 | concurrency: |
| 11 | group: ci-${{ github.workflow }}-${{ github.ref }} |
| 12 | cancel-in-progress: true |
| 13 | |
| 14 | env: |
| 15 | CI: true |
| 16 | NEXT_TELEMETRY_DISABLED: "1" |
| 17 | |
| 18 | jobs: |
| 19 | lint: |
| 20 | name: Lint |
| 21 | runs-on: ubuntu-latest |
| 22 | |
| 23 | steps: |
| 24 | - name: Checkout |
| 25 | uses: actions/checkout@v6 |
| 26 | |
| 27 | - name: Setup pnpm |
| 28 | uses: pnpm/action-setup@v6 |
| 29 | with: |
| 30 | version: 9 |
| 31 | run_install: false |
| 32 | |
| 33 | - name: Setup Node.js |
| 34 | uses: actions/setup-node@v6 |
| 35 | with: |
| 36 | node-version-file: .nvmrc |
| 37 | cache: pnpm |
| 38 | cache-dependency-path: pnpm-lock.yaml |
| 39 | |
| 40 | - name: Install dependencies |
| 41 | run: pnpm install --frozen-lockfile |
| 42 | |
| 43 | - name: Run ESLint |
| 44 | run: pnpm lint |
| 45 | |
| 46 | build: |
| 47 | name: Build |
| 48 | runs-on: ubuntu-latest |
| 49 | |
| 50 | steps: |
| 51 | - name: Checkout |
| 52 | uses: actions/checkout@v6 |
| 53 | |
| 54 | - name: Setup pnpm |
| 55 | uses: pnpm/action-setup@v6 |
| 56 | with: |
| 57 | version: 9 |
| 58 | run_install: false |
| 59 | |
| 60 | - name: Setup Node.js |
| 61 | uses: actions/setup-node@v6 |
| 62 | with: |
| 63 | node-version-file: .nvmrc |
| 64 | cache: pnpm |
| 65 | cache-dependency-path: pnpm-lock.yaml |
| 66 | |
| 67 | - name: Install dependencies |
| 68 | run: pnpm install --frozen-lockfile |
| 69 | |
| 70 | - name: Build Next.js app |
| 71 | run: pnpm build |