Merge pull request #56 from AI-agent-assembly/v0.0.1/AAASM-1218/feat/… #29
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: documentation | |
| on: | |
| push: | |
| branches: | |
| - "master" | |
| paths: | |
| # Doc — CI workflow + deploy scripts | |
| - ".github/workflows/documentation.yaml" | |
| - "scripts/ci/deploy-latest-version-documentation.sh" | |
| - "scripts/ci/deploy-stable-version-documentation.sh" | |
| # Doc — MkDocs config | |
| - "mkdocs.yml" | |
| # Doc — Markdown content | |
| - "docs/**/*.md" | |
| # Doc — theme overrides | |
| - "docs/_overrides/**" | |
| # Python source code (mkdocstrings reads docstrings from agent_assembly/) | |
| - "agent_assembly/**/*.py" | |
| # Python project metadata (version is read from pyproject.toml) | |
| - "pyproject.toml" | |
| workflow_run: | |
| workflows: ["release"] | |
| types: [completed] | |
| branches: ["master"] | |
| permissions: | |
| contents: write | |
| id-token: write | |
| pages: write | |
| # Allow one concurrent deployment so a fast-follow push doesn't race the | |
| # previous deploy on gh-pages. | |
| concurrency: | |
| group: "pages-mkdocs" | |
| cancel-in-progress: true | |
| jobs: | |
| deploy_latest_documentation: | |
| name: Deploy latest documentation | |
| if: github.event_name == 'push' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout (full history for mike + git-revision-date plugins) | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| - name: Install Python 3.13 | |
| run: uv python install 3.13 | |
| - name: Install docs dependency group | |
| run: uv sync --group docs | |
| - name: Print tool versions | |
| run: | | |
| uv run mkdocs --version | |
| uv run mike --version | |
| - name: Build and deploy latest documentation | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| MKDOCS_GIT_COMMITTERS_APIKEY: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| # Activate the uv-managed venv so the deploy script's `mkdocs` and | |
| # `mike` commands resolve without the `uv run` prefix. | |
| source .venv/bin/activate | |
| bash ./scripts/ci/deploy-latest-version-documentation.sh | |
| deploy_stable_documentation: | |
| name: Deploy stable documentation (release) | |
| if: | | |
| github.event_name == 'workflow_run' && | |
| github.event.workflow_run.conclusion == 'success' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout (full history for mike + git-revision-date plugins) | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| ref: master | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| - name: Install Python 3.13 | |
| run: uv python install 3.13 | |
| - name: Install docs dependency group | |
| run: uv sync --group docs | |
| - name: Print tool versions | |
| run: | | |
| uv run mkdocs --version | |
| uv run mike --version | |
| - name: Build and deploy stable documentation | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| MKDOCS_GIT_COMMITTERS_APIKEY: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| source .venv/bin/activate | |
| bash ./scripts/ci/deploy-stable-version-documentation.sh | |
| - name: Deployment summary | |
| env: | |
| STABLE_URL: "https://ai-agent-assembly.github.io/python-sdk/stable/" | |
| run: | | |
| { | |
| echo "## 📚 Stable documentation deployed" | |
| echo "🔗 ${STABLE_URL}" | |
| } >> "$GITHUB_STEP_SUMMARY" |