|
58 | 58 | COMMIT_MESSAGE: ${{ github.event.head_commit.message }}
|
59 | 59 | run: |
|
60 | 60 | cd src/ci/citool
|
61 |
| - cargo test |
62 |
| - cargo run calculate-job-matrix >> $GITHUB_OUTPUT |
| 61 | + CARGO_INCREMENTAL=0 cargo test |
| 62 | + CARGO_INCREMENTAL=0 cargo run calculate-job-matrix >> $GITHUB_OUTPUT |
63 | 63 | id: jobs
|
64 | 64 | job:
|
65 | 65 | name: ${{ matrix.full_name }}
|
@@ -182,6 +182,13 @@ jobs:
|
182 | 182 | - name: show the current environment
|
183 | 183 | run: src/ci/scripts/dump-environment.sh
|
184 | 184 |
|
| 185 | + # Pre-build citool before the following step uninstalls rustup |
| 186 | + # Build it into the build directory, to avoid modifying sources |
| 187 | + - name: build citool |
| 188 | + run: | |
| 189 | + cd src/ci/citool |
| 190 | + CARGO_INCREMENTAL=0 CARGO_TARGET_DIR=../../../build/citool cargo build |
| 191 | +
|
185 | 192 | - name: run the build
|
186 | 193 | # Redirect stderr to stdout to avoid reordering the two streams in the GHA logs.
|
187 | 194 | run: src/ci/scripts/run-build-from-ci.sh 2>&1
|
@@ -218,16 +225,22 @@ jobs:
|
218 | 225 | # erroring about invalid credentials instead.
|
219 | 226 | if: github.event_name == 'push' || env.DEPLOY == '1' || env.DEPLOY_ALT == '1'
|
220 | 227 |
|
| 228 | + - name: postprocess metrics into the summary |
| 229 | + run: | |
| 230 | + if [ -f build/metrics.json ]; then |
| 231 | + ./build/citool/debug/citool postprocess-metrics build/metrics.json ${GITHUB_STEP_SUMMARY} |
| 232 | + elif [ -f obj/build/metrics.json ]; then |
| 233 | + ./build/citool/debug/citool postprocess-metrics obj/build/metrics.json ${GITHUB_STEP_SUMMARY} |
| 234 | + else |
| 235 | + echo "No metrics.json found" |
| 236 | + fi |
| 237 | +
|
221 | 238 | - name: upload job metrics to DataDog
|
222 | 239 | if: needs.calculate_matrix.outputs.run_type != 'pr'
|
223 | 240 | env:
|
224 |
| - DATADOG_SITE: datadoghq.com |
225 | 241 | DATADOG_API_KEY: ${{ secrets.DATADOG_API_KEY }}
|
226 | 242 | DD_GITHUB_JOB_NAME: ${{ matrix.full_name }}
|
227 |
| - run: | |
228 |
| - cd src/ci |
229 |
| - npm ci |
230 |
| - python3 scripts/upload-build-metrics.py ../../build/cpu-usage.csv |
| 243 | + run: ./build/citool/debug/citool upload-build-metrics build/cpu-usage.csv |
231 | 244 |
|
232 | 245 | # This job isused to tell bors the final status of the build, as there is no practical way to detect
|
233 | 246 | # when a workflow is successful listening to webhooks only in our current bors implementation (homu).
|
|
0 commit comments