File indexing completed on 2024-05-12 04:44:28
0001 #!/bin/bash 0002 0003 # SPDX-FileCopyrightText: Lukas Sommer <sommerluk@gmail.com> 0004 # SPDX-License-Identifier: BSD-2-Clause OR MIT 0005 0006 0007 0008 0009 0010 # Use “totalerrors” and not “errorcount” like in the called scripts, 0011 # to avoid conflicts. 0012 totalerrors=0 0013 0014 echo "Starting ci-staticcodecheck.sh …" 0015 scripts/ci-staticcodecheck.sh 0016 exitcode=$? 0017 totalerrors=$((totalerrors + exitcode)) 0018 echo "ci-staticcodecheck.sh finished with exit code $exitcode." 0019 exitcode_staticcodecheck=$exitcode 0020 0021 echo "Starting ci-cmakelint.sh …" 0022 scripts/ci-cmakelint.sh 0023 exitcode=$? 0024 totalerrors=$((totalerrors + exitcode)) 0025 echo "ci-cmakelint.sh finished with exit code $exitcode." 0026 exitcode_cmakelint=$exitcode 0027 0028 echo "Starting ci-format.sh …" 0029 scripts/ci-format.sh 0030 exitcode=$? 0031 totalerrors=$((totalerrors + exitcode)) 0032 echo "ci-format.sh finished with exit code $exitcode." 0033 exitcode_automatic_integration=$exitcode 0034 0035 echo "Starting ci-doxygen.sh …" 0036 scripts/ci-doxygen.sh 0037 exitcode=$? 0038 totalerrors=$((totalerrors + exitcode)) 0039 echo "ci-doxygen.sh finished with exit code $exitcode." 0040 exitcode_doxygen=$exitcode 0041 0042 echo "Starting ci-ipo-lto …" 0043 scripts/ci-ipo-lto.sh 0044 exitcode=$? 0045 totalerrors=$((totalerrors + exitcode)) 0046 echo "ci-ipo-lto finished with exit code $exitcode." 0047 exitcode_ipo_lto=$exitcode 0048 0049 echo "Starting ci-qch.sh …" 0050 scripts/ci-qch.sh 0051 exitcode=$? 0052 totalerrors=$((totalerrors + exitcode)) 0053 echo "ci-qch.sh finished with exit code $exitcode." 0054 exitcode_qch=$exitcode 0055 0056 echo "Starting ci-warnings.sh …" 0057 scripts/ci-warnings.sh 0058 exitcode=$? 0059 totalerrors=$((totalerrors + exitcode)) 0060 echo "ci-warnings.sh finished with exit code $exitcode." 0061 exitcode_warnings=$exitcode 0062 0063 echo "Starting ci-iwyu.sh …" 0064 scripts/ci-iwyu.sh 0065 exitcode=$? 0066 # NOTE Do NOT count this exit code. There is a separate job that will 0067 # use iwyu artifacts later… 0068 echo "ci-iwyu.sh finished with exit code $exitcode." 0069 exitcode_iwyu=$exitcode 0070 0071 # Delete empty artifacts 0072 echo "BEGIN list of artifacts" 0073 for file in artifact_* 0074 do 0075 if [ -s "$file" ] 0076 then 0077 echo "$file" 0078 else 0079 rm "$file" 0080 fi 0081 done 0082 echo "END list of artifacts" 0083 0084 echo "Exit codes:" 0085 echo "staticcodecheck: $exitcode_staticcodecheck" 0086 echo "cmakelint: $exitcode_cmakelint" 0087 echo "automatic_integration: $exitcode_automatic_integration" 0088 echo "doxygen: $exitcode_doxygen" 0089 echo "ipo_lto: $exitcode_ipo_lto" 0090 echo "qch: $exitcode_qch" 0091 echo "warnings: $exitcode_warnings" 0092 echo "iwyu: $exitcode_iwyu (ignored)" 0093 echo 0094 echo "Terminating ci.sh with exit code $totalerrors." 0095 # NOTE The exit code of the last command is available with $? in the shell. 0096 exit $totalerrors