Skip to content

Generate Sphinx Index file via GitHub Actions #5

Generate Sphinx Index file via GitHub Actions

Generate Sphinx Index file via GitHub Actions #5

Workflow file for this run

name: shinx
on:
push:
branches: [main]
pull_request:
branches: [main]
release:
types: [published]
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
jobs:
build:

Check failure on line 19 in .github/workflows/sphinx.yaml

View workflow run for this annotation

GitHub Actions / shinx

Invalid workflow file

The workflow is not valid. .github/workflows/sphinx.yaml (Line: 19, Col: 5): The workflow must contain at least one job with no dependencies.
needs: render-docs
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
# Setting up the environment
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Set up Quarto
uses: quarto-dev/quarto-actions/setup@v2
with:
version: 1.4.515
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install Poetry
run: pip install poetry
- name: Install dependencies with Poetry
run: poetry install -C docs
# Building
- name: Render Quarto File
run: quarto render README.qmd --to rst && mv README.rst docs/index.rst
- name: Build HTML using Poetry
run: poetry run -C docs sphinx-build -M html docs/source/ docs/build/
# Upload
- name: Upload artifacts
uses: actions/upload-pages-artifact@v3
with:
name: github-pages
path: docs/build/html/
deploy:
# Deploy to the github-pages environment
# but not on PRs
if: ${{ github.event_name != 'pull_request' }}
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
needs: build
# Specify runner + deployment step
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
with:
artifact_name: github-pages
preview: true # Not yet available to the public.