Browse Source

Decrease CPU count by one to try and stop GHA from killing runners. (#23826)

Nick Brassel 2 years ago
parent
commit
395766657f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      .github/workflows/ci_build_major_branch_keymap.yml

+ 1 - 1
.github/workflows/ci_build_major_branch_keymap.yml

@@ -108,7 +108,7 @@ jobs:
       - name: Build targets
         continue-on-error: true
         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) -1 ))
           qmk mass-compile -t -j $NCPUS -e DUMP_CI_METADATA=yes $(jq -r '.["${{ matrix.target }}"].targets' targets.json) || touch .failed
 
       - name: Upload binaries