mirror of
https://github.com/senju1337/senju.git
synced 2025-12-24 07:39:29 +00:00
chore: deploy docs to github pages and manual artifacts
Refs: OPS-63
This commit is contained in:
parent
46ec800ae6
commit
9b9b13d103
1 changed files with 30 additions and 14 deletions
44
.github/workflows/gendocs.yml
vendored
44
.github/workflows/gendocs.yml
vendored
|
|
@ -5,14 +5,18 @@ on:
|
|||
branches:
|
||||
- master
|
||||
- devel
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
- devel
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
pages: write
|
||||
id-token: write
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v3
|
||||
|
|
@ -23,16 +27,28 @@ jobs:
|
|||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install sphinx
|
||||
pip install sphinx poetry
|
||||
poetry install
|
||||
- name: Build Sphinx documentation
|
||||
run: |
|
||||
cd docs
|
||||
sphinx-apidoc -o source/_modules ../senju
|
||||
make html
|
||||
- name: Upload documentation artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
cd docs && ls
|
||||
bash auto_docu.sh
|
||||
- name: Upload documentation files as artifact
|
||||
id: deployment
|
||||
uses: actions/upload-pages-artifact@v3 # or specific "vX.X.X" version tag for this action
|
||||
with:
|
||||
name: documentation-artifact
|
||||
path: docs/build/html
|
||||
# TODO: upload artifact for gh pages
|
||||
# TODO: deploy to gh pages
|
||||
path: docs/build/html/
|
||||
|
||||
deploy:
|
||||
needs: build
|
||||
|
||||
# Deploy to the github-pages environment
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Deploy to GitHub Pages
|
||||
id: deployment
|
||||
uses: actions/deploy-pages@v4
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue