name: Deploy docs

on:
  push:
    branches: [main]
  workflow_dispatch:

permissions:
  contents: write

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 0

      - uses: astral-sh/setup-uv@v5

      - name: Prepare docs assets
        run: |
          mkdir -p guide/assets
          cp icon.svg guide/assets/icon.svg

      - name: Deploy to GitHub Pages
        run: uv run mkdocs gh-deploy --force
