Skip to content

adding github workflows for documentation and tests #1

adding github workflows for documentation and tests

adding github workflows for documentation and tests #1

Workflow file for this run

name: docs
on:
push:
branches:
- main
- final_project
jobs:
docs:
name: Docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: "3.10.16"
- name: Set up Python environment
run: |
python -m venv venv
source venv/bin/activate
- name: Install dependencies
run: |
source venv/bin/activate
python -m pip install .
- name: Generate documentation
run: |
source venv/bin/activate
cd docs
make html
- name: Upload documentation
if: success()
uses: actions/upload-artifact@v3
with:
name: documentation
path: docs/build/html/
- name: Deploy
if: success() && github.ref == 'refs/heads/main'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/build/html
allow_empty_commit: true