Skip to content

Commit fcc3efc

Browse files
feat: add summary reporting for AIBOM validation scores in integration workflow
1 parent 6275842 commit fcc3efc

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

.github/workflows/integration.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,8 @@ jobs:
7878
fi
7979
rm -rf "${REPORT_DIR}"
8080
mkdir -p "${REPORT_DIR}"
81+
SUMMARY_FILE="${REPORT_DIR}/scores.txt"
82+
: > "${SUMMARY_FILE}"
8183
for file in "${bom_files[@]}"; do
8284
if [ ! -s "$file" ]; then
8385
echo "Generated file $file is empty"
@@ -91,8 +93,22 @@ jobs:
9193
--log-level debug \
9294
--strict \
9395
--min-score 0.5 2>&1 | tee "$LOG"
96+
score_line=$(grep -E 'completeness score:' "$LOG" | tail -1 || true)
97+
if [ -z "$score_line" ]; then
98+
score_line="completeness score: unavailable"
99+
fi
100+
summary_entry="$base: $score_line"
101+
echo "$summary_entry" | tee -a "$SUMMARY_FILE"
94102
done
95103
104+
if [ -n "${GITHUB_STEP_SUMMARY:-}" ]; then
105+
{
106+
echo "### ${FIXTURE} | ${OUTPUT_FORMAT} | ${HF_MODE}"
107+
cat "$SUMMARY_FILE"
108+
echo
109+
} >> "${GITHUB_STEP_SUMMARY}"
110+
fi
111+
96112
- name: Upload AIBOM artifacts
97113
uses: actions/upload-artifact@v4
98114
with:

0 commit comments

Comments
 (0)