Skip to content

feat(ci): add documentation preview and GitHub Pages workflows#3

Merged
JacobCoffee merged 3 commits intomainfrom
docs-workflows
Nov 27, 2025
Merged

feat(ci): add documentation preview and GitHub Pages workflows#3
JacobCoffee merged 3 commits intomainfrom
docs-workflows

Conversation

@JacobCoffee
Copy link
Owner

Summary

  • Add docs.yml workflow for building documentation on PRs and pushes to main
  • Add pages-deploy.yml workflow for GitHub Pages deployment from gh-pages branch
  • PR preview comments via rossjrw/pr-preview-action when docs or src changes
  • Smart path filtering to only build when relevant files change

Setup Required

After merging, enable GitHub Pages in repo settings:

  1. Go to Settings → Pages
  2. Set Source to "GitHub Actions"

Test plan

  • Verify workflow syntax is valid
  • Test PR preview by making a docs change in a subsequent PR
  • Confirm GitHub Pages deploys after merge to main

🤖 Generated with Claude Code

- Add docs.yml for building docs on PR/push with PR preview comments
- Add pages-deploy.yml for GitHub Pages deployment from gh-pages branch
- Triggers on docs/ and src/ changes (source affects autodoc)
- Uses rossjrw/pr-preview-action for PR preview links

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings November 27, 2025 06:26
@JacobCoffee JacobCoffee enabled auto-merge (squash) November 27, 2025 06:26
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds GitHub Actions workflows for building and deploying Sphinx documentation with PR preview capabilities. The implementation introduces two workflows: docs.yml for building documentation on PRs and pushes to main, and pages-deploy.yml for deploying from a gh-pages branch. The PR implements smart path filtering to build only when docs or source code changes.

  • Adds automated documentation building with Sphinx using uv for dependency management
  • Implements PR preview functionality via rossjrw/pr-preview-action for documentation changes
  • Sets up GitHub Pages deployment infrastructure with two separate workflows

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
.github/workflows/docs.yml Main documentation workflow with build job, path filtering, PR previews, and GitHub Pages deployment from main branch
.github/workflows/pages-deploy.yml Separate workflow to deploy from gh-pages branch to GitHub Pages

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

JacobCoffee

This comment was marked as outdated.

Autosummary needs to import all modules to generate API docs, which
requires litestar and sqlalchemy optional dependencies.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@github-actions
Copy link
Contributor

github-actions bot commented Nov 27, 2025

PR Preview Action v1.6.3

🚀 View preview at
https://JacobCoffee.github.io/debug-toolbar/pr-preview/pr-3/

Built to branch gh-pages at 2025-11-27 06:41 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

Copilot AI review requested due to automatic review settings November 27, 2025 06:40
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +72 to +76
- name: Upload artifact for GitHub Pages
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
uses: actions/upload-pages-artifact@56afc609e74202658d3ffba0e8f6dda462b719fa # v3.0.1
with:
path: docs/_build/html
Copy link

Copilot AI Nov 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing actions/configure-pages step before uploading the Pages artifact. The configure-pages action must be called before upload-pages-artifact to properly set up the Pages environment. Add this step before line 72: - name: Setup Pages\n uses: actions/configure-pages@983d7736d9b0ae728b81ab479565c72886d7745b # v5.0.0

Copilot uses AI. Check for mistakes.
@JacobCoffee JacobCoffee disabled auto-merge November 27, 2025 06:44
@JacobCoffee JacobCoffee merged commit 8939398 into main Nov 27, 2025
9 checks passed
@JacobCoffee JacobCoffee deleted the docs-workflows branch November 27, 2025 06:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants