name: Docs deploy
permissions:
  contents: read

on:
  workflow_dispatch:
  push:
    branches:
      - main
    paths:
      - "apps/docs/**"

jobs:
  deploy:
    name: Deploy docs
    runs-on: ubuntu-latest
    timeout-minutes: 10

    steps:
      - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6

      - name: Install dependencies
        uses: "./.github/actions/install-dependencies"

      - name: Build docs
        working-directory: apps/docs
        run: bun run build

      - name: Build and deploy docs
        uses: cloudflare/wrangler-action@ebbaa1584979971c8614a24965b4405ff95890e0 # v4
        with:
          apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
          accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
          workingDirectory: apps/docs






