CICD-031 · Write a readable run summary
Encyclopedia · Variables, outputs and data flow · All snippets
Previous · CICD-030 · Next · CICD-032
1. Where it fits
- Placement Bash run step following checkout, or equivalent lab terminal.
- Prerequisites GitHub Actions job or equivalent Gitea version with environment file support.
- Platforms local-linux, github-actions, gitea-actions.
- Parameters
GITHUB_SHA,GITHUB_STEP_SUMMARY.
2. Copy the snippet
bash
printf '### CI evidence\n\nCommit: `%s`\n' "$GITHUB_SHA" >> "$GITHUB_STEP_SUMMARY"3. How it works
GITHUB_STEP_SUMMARY is a runner-managed file for Markdown. Append to it within the step and the run page can render the commit without opening the raw log.
4. Verify the result
The job summary should show the commit without downloading a log file.
Validation syntax-validated (Bash parse). Status definitions.