-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Overview
Three independent improvements to the CI skeleton template that each improve cross-platform correctness and debuggability.
1. Use `fetch-depth: 1` in analyze and test jobs
Current: Only `pre-check` uses shallow clone. `analyze` and `test` do full history clone (default).
Impact: ~50-150 seconds wasted per workflow run (5 full clones for 4-platform matrix + analyze).
Fix: Add `fetch-depth: 1` to checkout in both `analyze` and `test` jobs.
2. Use `$RUNNER_TEMP` instead of `/tmp/` in non-managed analyze
Current: Non-managed analyze uses `/tmp/analysis.txt` which doesn't exist on Windows.
Impact: Latent — non-managed analyze currently only runs on ubuntu. But if someone adds sub-package analysis in a matrix context, it breaks on Windows.
Fix: `$RUNNER_TEMP/analysis.txt` works on all platforms.
3. Add artifact upload on test failure
Current: No diagnostic artifacts uploaded when tests fail. Debugging cross-platform CI failures is blind.
Fix: Add conditional artifact upload:
- name: Upload test artifacts on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: test-artifacts-\${{ matrix.os }}
path: |
test/integration/fixtures/bin/
**/test-results/
retention-days: 7Acceptance Criteria
- All checkout steps use `fetch-depth: 1`
- `/tmp/` replaced with `$RUNNER_TEMP` where applicable
- Artifact upload step added to test job (multi-platform path)
- Template updated in all relevant locations