Repository navigation
Merge pull request #207 from bonachea/assert-update #992
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: Build and Deploy Documentation | |
| on: [push, pull_request] | |
| concurrency: | |
| # De-duplicate concurrent workflow runs on the same branch/ref | |
| group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
| permissions: | |
| contents: write | |
| pages: write | |
| jobs: | |
| Build: | |
| name: FORD docs | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Install Dependencies Ubuntu | |
| run: | | |
| sudo apt-get update | |
| sudo apt install -y python3-dev python3 build-essential graphviz | |
| sudo python3 -m pip install ford | |
| - name: Create Assert placeholder header file | |
| run: | | |
| # Placeholder Assert include file so FORD can complete preprocess | |
| FILE=include/assert_macros.h | |
| echo "#define call_assert(assertion)" > $FILE | |
| echo "#define call_assert_describe(assertion, description)" >> $FILE | |
| - name: Build Developer Documenation | |
| run: | | |
| ford -I include ford.md | |
| - name: Upload Documentation | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: documentation | |
| path: doc/html | |
| if-no-files-found: error | |
| - name: Broken Link Check | |
| if: ${{ github.ref == 'refs/heads/main'}} | |
| uses: technote-space/broken-link-checker-action@v1 | |
| with: | |
| TARGET: file://${{ github.workspace }}/doc/html/index.html | |
| RECURSIVE: true | |
| ASSIGNEES: ${{ github.actor }} | |
| - name: Deploy API Documentation | |
| uses: JamesIves/github-pages-deploy-action@4.1.0 | |
| if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} | |
| with: | |
| branch: gh-pages | |
| folder: doc/html |