CI, DOC: Separate docs build from CI test jobs, deployment #17
Workflow file for this run
This file contains hidden or 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 CI | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| docs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install -v ".[test]" | |
| python -m pip install ruff==0.13.1 | |
| python -m pip install -r .github/constraints/deps.txt | |
| - name: lint | |
| run: | | |
| ruff check | |
| - name: lint and build docs | |
| run: | | |
| numpydoc lint src/gfdl/model.py src/gfdl/activations.py src/gfdl/weights.py | |
| cd docs && make html SPHINXOPTS="-W --keep-going" | |
| - name: upload PR artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| path: docs/build/html |