Skip to content

update workflow + update code with feedback #32

update workflow + update code with feedback

update workflow + update code with feedback #32

Workflow file for this run

name: Documentation
on:
push:
branches:
- xiaoyi_doc # Ensure this is the branch where you commit documentation updates
permissions:
contents: write
actions: read
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install dependencies
run: |
pip install --upgrade pip
pip install -r ./docs/requirements.txt
pip freeze # Display installed packages for debugging
- name: Build documentation
run: |
sphinx-build -b html ./docs/source/ ./docs/build/ -v
ls -l ./docs/build/ # List output files for debugging
- name: Create .nojekyll file
run: touch ./docs/build/.nojekyll
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_branch: gh-pages # Ensure this is the branch for GitHub Pages
publish_dir: ./docs/build/
user_name: github-actions[bot] # Automated commit user name
user_email: github-actions[bot]@users.noreply.github.com
- name: Debug Output
run: |
pwd # Print the current working directory
ls -l # List files in the current directory
cat ./docs/source/conf.py # Show Sphinx config file for debugging