Skip to content

Commit

Permalink
Merge pull request #27 from muon-spectroscopy-computational-project/2…
Browse files Browse the repository at this point in the history
…1-add-ci-to-deploy-documentation

add gh workflow to deploy documentation pages
  • Loading branch information
subindev-d authored Jul 16, 2024
2 parents 24e873e + 7c0f285 commit f49cd67
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
#Workflow to deploy sphinx documentation to github pages

name: Deploy Sphinx Documentation

on:
push:
branches: ['main']
paths: ['docs/**']

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install sphinx sphinx_rtd_theme
- name: Build documentation
id: build-docs
run: |
sphinx-build -M html docs/source docs/build
- name: Deploy to Github pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/build/html

0 comments on commit f49cd67

Please sign in to comment.