-
Notifications
You must be signed in to change notification settings - Fork 33
Add Great Docs documentation site #44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 4 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
96592e3
Add great-docs to dev dependency group
cak 8578268
Add Great Docs build directories to .gitignore
cak 875985b
Add great-docs.yml configuration file
cak f681fce
Add GitHub Actions workflow for documentation generation
cak 8320258
Potential fix for pull request finding 'CodeQL / Workflow does not co…
cak File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,110 @@ | ||
| name: CI Docs | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| pull_request: | ||
|
|
||
| jobs: | ||
| build-docs: | ||
| name: "Build Docs" | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v6 | ||
| with: | ||
| fetch-depth: 0 # Full history for accurate page timestamps | ||
|
|
||
| - uses: actions/setup-python@v6 | ||
| with: | ||
| python-version: "3.11" | ||
|
|
||
| - name: Install package and dependencies | ||
| run: | | ||
| python -m pip install uv | ||
| uv sync | ||
| uv pip install great-docs | ||
|
|
||
| - name: Set up Quarto | ||
| uses: quarto-dev/quarto-actions/setup@v2 | ||
|
|
||
| - name: Build docs | ||
| run: uv run great-docs build | ||
|
|
||
| - name: Save docs artifact | ||
| uses: actions/upload-artifact@v7 | ||
| with: | ||
| name: docs-html | ||
| path: great-docs/_site | ||
| include-hidden-files: true | ||
|
|
||
| - name: Upload build timings | ||
| uses: actions/upload-artifact@v7 | ||
| with: | ||
| name: build-timings | ||
| path: great-docs/_site/build-timings.json | ||
|
|
||
| publish-docs: | ||
| name: "Publish Docs" | ||
| runs-on: ubuntu-latest | ||
| needs: "build-docs" | ||
| if: github.ref == 'refs/heads/main' | ||
| permissions: | ||
| pages: write | ||
| id-token: write | ||
| environment: | ||
| name: github-pages | ||
| url: ${{ steps.deployment.outputs.page_url }} | ||
| steps: | ||
| - uses: actions/download-artifact@v7 | ||
| with: | ||
| name: docs-html | ||
| path: great-docs/_site | ||
|
|
||
| - name: Upload Pages artifact | ||
| uses: actions/upload-pages-artifact@v5 | ||
| with: | ||
| path: great-docs/_site | ||
| include-hidden-files: true | ||
|
|
||
| - name: Deploy to GitHub Pages | ||
| id: deployment | ||
| uses: actions/deploy-pages@v5 | ||
|
|
||
| preview-docs: | ||
| name: "Preview Docs" | ||
| runs-on: ubuntu-latest | ||
| needs: "build-docs" | ||
| if: github.event_name == 'pull_request' | ||
| permissions: | ||
| deployments: write | ||
| pull-requests: write | ||
| steps: | ||
| - uses: actions/download-artifact@v7 | ||
| with: | ||
| name: docs-html | ||
| path: great-docs/_site | ||
|
|
||
| # Start deployment | ||
| - name: Configure pull release name | ||
| if: ${{ github.event_name == 'pull_request' }} | ||
| run: | | ||
| echo "RELEASE_NAME=pr-${{ github.event.number }}" >> $GITHUB_ENV | ||
|
|
||
| - name: Configure branch release name | ||
| if: ${{ github.event_name != 'pull_request' }} | ||
| run: | | ||
| # use branch name, but replace slashes. E.g. feat/a -> feat-a | ||
| echo "RELEASE_NAME=${GITHUB_REF_NAME//\//-}" >> $GITHUB_ENV | ||
|
|
||
| # Deploy | ||
| - name: Create Github Deployment | ||
| uses: bobheadxi/deployments@v1 | ||
| id: deployment | ||
| if: ${{ !github.event.pull_request.head.repo.fork }} | ||
| with: | ||
| step: start | ||
| token: ${{ secrets.GITHUB_TOKEN }} | ||
| env: ${{ env.RELEASE_NAME }} | ||
| ref: ${{ github.head_ref }} | ||
| logs: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" | ||
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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.