Merge pull request #16 from pylhc/sps_remove_trailing_planes #51
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
# Build documentation | |
name: Build and upload documentation | |
defaults: | |
run: | |
shell: bash | |
on: # Runs on any push event to master | |
push: | |
branches: | |
- 'master' | |
jobs: | |
documentation: | |
name: ${{ matrix.os }} / ${{ matrix.python-version }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
python-version: [3.9] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: 'pip' | |
cache-dependency-path: '**/setup.py' | |
- name: Upgrade pip, setuptools and wheel | |
run: python -m pip install --upgrade pip setuptools wheel | |
- name: Install package | |
run: python -m pip install '.[doc]' | |
- name: Build documentation | |
run: python -m sphinx -b html doc ./doc_build -d ./doc_build | |
- name: Upload documentation to gh-pages | |
if: ${{ success() }} | |
uses: JamesIves/github-pages-deploy-action@3.7.1 | |
with: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
BRANCH: gh-pages | |
FOLDER: doc_build |