portability #187
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 + Coverage | |
| on: | |
| push: | |
| branches: [ "master" ] | |
| pull_request: | |
| branches: [ "master" ] | |
| permissions: | |
| contents: write | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Install GCC and coverage tools | |
| run: | | |
| sudo apt update | |
| sudo apt install gcc g++ lcov | |
| - name: Build with Make | |
| run: make | |
| - name: Run coverage script | |
| run: Tools/build/docov | |
| - name: Upload coverage result as artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: coverage-report | |
| path: coverage-dir/rapport | |
| - name: Debug coverage output | |
| run: ls -R coverage-dir/rapport | |
| - name: Deploy coverage to GitHub Pages | |
| if: github.ref == 'refs/heads/master' | |
| uses: peaceiris/actions-gh-pages@v3 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: coverage-dir/rapport |