Update index.rst #138
This file contains 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: "Docs / Publish" | |
# For more information, | |
# see https://sphinx-theme.scylladb.com/stable/deployment/production.html#available-workflows | |
on: | |
push: | |
branches: | |
- master | |
- 'branch-**' | |
paths: | |
- "docs/**" | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.repository.default_branch }} | |
persist-credentials: false | |
fetch-depth: 0 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.10' | |
- name: Set up env | |
run: make -C docs setupenv | |
- name: Build docs | |
run: make -C docs multiversion | |
- name: Build redirects | |
run: make -C docs redirects | |
- name: Tar folder | |
run: | | |
tar \ | |
--dereference --hard-dereference \ | |
--directory docs/_build/dirhtml/ \ | |
-cvf ${{ runner.temp }}/artifact.tar \ | |
. | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4.3.3 | |
with: | |
name: github-pages | |
path: ${{ runner.temp }}/artifact.tar | |
retention-days: "1" | |
release: | |
# Add a dependency to the build job | |
needs: build | |
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment | |
permissions: | |
pages: write # to deploy to Pages | |
id-token: write # to verify the deployment originates from an appropriate source | |
contents: read # to read private repo | |
# Deploy to the github-pages environment | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
# Specify runner + deployment step | |
runs-on: ubuntu-latest | |
steps: | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v4 |