Skip to content

Check that docs deploy (#885) #459

Check that docs deploy (#885)

Check that docs deploy (#885) #459

Workflow file for this run

name: PeleC-Docs
on:
push:
branches: [development]
paths:
- 'Docs/**'
- 'README.rst'
- '.github/workflows/docs.yml'
pull_request:
branches: [development]
paths:
- 'Docs/**'
- 'README.rst'
- '.github/workflows/docs.yml'
jobs:
Docs:
runs-on: ubuntu-24.04
steps:
- name: Clone
uses: actions/checkout@v4
- name: Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Dependencies
run: |
#Currently ignoring doxygen
#sudo apt-get update
#sudo apt-get install -y --no-install-recommends doxygen graphviz
python -m pip install --upgrade pip
pip install sphinx sphinx_rtd_theme
- name: Configure
run: cmake -B${{runner.workspace}}/build-docs ${{github.workspace}}/Docs
- name: Build
working-directory: ${{runner.workspace}}/build-docs
run: |
echo "::add-matcher::.github/problem-matchers/sphinx.json"
cmake --build ${{runner.workspace}}/build-docs 2>&1 | tee -a build-output.txt
touch ${{runner.workspace}}/build-docs/sphinx/html/.nojekyll
- name: Report
working-directory: ${{runner.workspace}}/build-docs
run: |
echo "::add-matcher::.github/problem-matchers/sphinx.json"
egrep "WARNING:|Warning:|ERROR:|Error:" build-output.txt | sort | uniq | \
awk 'BEGIN{i=0}{print $0}{i++}END{print "Warnings: "i}' > build-output-warnings.txt
cat build-output-warnings.txt
exit $(tail -n 1 build-output-warnings.txt | awk '{print $2}')
- name: Deploy
if: github.event_name == 'push' && github.ref == 'refs/heads/development'
uses: JamesIves/github-pages-deploy-action@releases/v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: gh-pages
folder: ${{runner.workspace}}/build-docs/sphinx/html
single-commit: true