Expanding navbar in the documentation by default #9
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: Deploy Sphinx documentation to Pages | |
on: | |
push: | |
branches: [main] # branch to trigger deployment | |
permissions: # Explicitly setting permissions | |
contents: write | |
pages: write | |
jobs: | |
build-and-deploy: | |
runs-on: ubuntu-22.04 # Specifies the runner environment | |
steps: | |
- name: Check out the repository | |
uses: actions/checkout@v3 # Checks out your repository under $GITHUB_WORKSPACE, so your workflow can access it | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.12' # Specify the Python version you need for your project | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Build Sphinx Documentation | |
run: | | |
chmod +x docs/rebuild-docs.sh | |
./docs/rebuild-docs.sh # Runs your script to build the documentation | |
- name: Prepare CNAME | |
run: echo 'perfsim.com' > docs/_build/html/CNAME # Creates a CNAME file in the publish directory | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./docs/_build/html # Directory where the built HTML files are located |