update dependencies #14
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: Documentation | |
on: | |
push: | |
branches: | |
- xiaoyi_doc | |
workflow_dispatch: | |
permissions: # This sets permissions for all jobs | |
contents: write | |
actions: read | |
jobs: | |
docs: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: List docs directory | |
run: ls -l ./docs | |
- name: Display requirements.txt | |
run: cat ./docs/requirements.txt | |
- name: Install dependencies | |
run: | | |
pip install -r ./docs/requirements.txt | |
pip freeze | |
- name: Sphinx build | |
run: | | |
sphinx-build -b html docs/source/ . # Change the output directory to root of the workspace | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v3 | |
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/xiaoyi_doc' }} | |
with: | |
publish_branch: xiaoyi_doc # Deploy directly to xiaoyi_doc | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./ # Set publish directory to the root of the branch | |
force_orphan: true |