name: Build Blog-only

on:
  pull_request:
    branches:
      - main
      - docusaurus-v**
    paths:
      - packages/**

concurrency:
  group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
  cancel-in-progress: true

permissions:
  contents: read

jobs:
  build:
    name: Build Blog-only
    timeout-minutes: 30
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
      - name: Set up Node
        uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
        with:
          node-version: lts/*
          cache: yarn
      - name: Installation
        run: yarn || yarn || yarn
      - name: Build blog-only
        run: yarn workspace website build:blogOnly
        env:
          DOCUSAURUS_PERF_LOGGER: 'true'
