Fixup CI command failures. (#20291)

This commit is contained in:
Nick Brassel 2023-03-29 16:48:57 +11:00 committed by GitHub
parent 6bdbf77238
commit d31d1488e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 3 deletions

View File

@ -39,11 +39,13 @@ jobs:
- name: Run `qmk mass-compile` (keymap ${{ matrix.keymap }}) - name: Run `qmk mass-compile` (keymap ${{ matrix.keymap }})
run: | run: |
export NCPUS=$(nproc 2>/dev/null || sysctl -n hw.ncpu 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) export NCPUS=$(nproc 2>/dev/null || sysctl -n hw.ncpu 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null)
qmk mass-compile -t -j $NCPUS -km ${{ matrix.keymap }} -e DUMP_CI_METADATA=yes qmk mass-compile -t -j $NCPUS -km ${{ matrix.keymap }} -e DUMP_CI_METADATA=yes || touch .failed
# Generate the step summary markdown # Generate the step summary markdown
./util/ci/generate_failure_markdown.sh > $GITHUB_STEP_SUMMARY ./util/ci/generate_failure_markdown.sh > $GITHUB_STEP_SUMMARY || true
# Truncate to a maximum of 1MB to deal with GitHub workflow limit # Truncate to a maximum of 1MB to deal with GitHub workflow limit
truncate --size='<960K' $GITHUB_STEP_SUMMARY truncate --size='<960K' $GITHUB_STEP_SUMMARY || true
# Exit with failure if the compilation stage failed
[ ! -f .failed ] || exit 1
- name: 'Upload artifacts' - name: 'Upload artifacts'
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3

View File

@ -19,3 +19,5 @@ dump_failure_info() {
for failure_file in $(find "$qmk_firmware_dir/.build" -name 'failed.log.*' | sort); do for failure_file in $(find "$qmk_firmware_dir/.build" -name 'failed.log.*' | sort); do
dump_failure_info "$failure_file" dump_failure_info "$failure_file"
done done
exit 0