Merge pull request #8 from open-metrify/graphql-client #39
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: Docs | |
on: | |
push: | |
tags: '*' | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build-docs: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Set up Python 3.12 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.12 | |
- name: Install | |
run: | | |
python -m pip install --upgrade pip | |
pip install poetry | |
poetry install --extras docs | |
- name: Build documentation | |
run: | | |
mkdir gh-pages | |
touch gh-pages/.nojekyll | |
cd docs/ | |
poetry run make html | |
cp -r build/html/* ../gh-pages/ | |
- name: Deploy documentation | |
if: ${{ github.event_name == 'push' }} | |
uses: JamesIves/[email protected] | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
branch: gh-pages | |
folder: gh-pages |