|
31 | 31 | run: git fetch origin main |
32 | 32 | - name: Detect Formatting Changes |
33 | 33 | shell: bash |
34 | | - run: python3 scripts/format_code.py -git_diff -noformat_file -verbose |
| 34 | + run: python3 scripts/format_code.py -git_diff -noformat_file -verbose -github_log |
35 | 35 |
|
36 | 36 | check_integration_test_labels: |
37 | 37 | # This check fails if integration tests are queued, in progress, or failed. |
|
42 | 42 | none_of: "${{ env.statusLabelInProgress }},${{ env.statusLabelFailed }},${{ env.triggerLabelFull }},${{ env.triggerLabelQuick }}" |
43 | 43 | repo_token: ${{ github.token }} |
44 | 44 |
|
45 | | - |
| 45 | + generated_docs_check: |
| 46 | + # This check succeeds if Doxygen documentation generates without errors. |
| 47 | + runs-on: ubuntu-latest |
| 48 | + steps: |
| 49 | + - uses: actions/checkout@v2 |
| 50 | + with: |
| 51 | + submodules: false |
| 52 | + - name: Setup python |
| 53 | + uses: actions/setup-python@v2 |
| 54 | + with: |
| 55 | + python-version: 3.7 |
| 56 | + - name: Install prerequisites |
| 57 | + run: python scripts/gha/install_prereqs_desktop.py |
| 58 | + - name: Generate headers |
| 59 | + run: | |
| 60 | + mkdir build |
| 61 | + cd build |
| 62 | + cmake .. |
| 63 | + cmake --build . --target FIREBASE_GENERATED_HEADERS |
| 64 | + - name: Install doxygen |
| 65 | + run: sudo apt-get install doxygen |
| 66 | + - name: Run doxygen |
| 67 | + run: | |
| 68 | + cp docs/Doxyfile /tmp/Doxyfile |
| 69 | + echo INPUT = $(find */src/include/firebase/ build/generated/ -name '*.h') >> /tmp/Doxyfile |
| 70 | + doxygen /tmp/Doxyfile 2>doxygen_errors.txt |
| 71 | + cat doxygen_errors.txt |
| 72 | + - name: Check output |
| 73 | + run: | |
| 74 | + if grep -Eq "error:|warning:" doxygen_errors.txt; then |
| 75 | + # Grep for warnings and print them out (replacing \n with %0A for github log) |
| 76 | + grep -E "error:|warning:|^ parameter" doxygen_errors.txt | sed ':a;N;$!ba;s/\n/%0A/g' | sed 's/^/::error ::DOXYGEN ERRORS: %0A/' |
| 77 | + exit 1 |
| 78 | + fi |
0 commit comments