Skip to content

Commit 7b1788e

Browse files
add check csv-header to githubCI
1 parent cac45ab commit 7b1788e

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.github/workflows/smoke-tests.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,5 +49,17 @@ jobs:
4949
if: failure()
5050
run: exit 1
5151

52+
- name: Check header in first line
53+
run: |
54+
HEADER="repository name,author name,author login,author email,date and time,changed files,commit id,branch"
55+
FIRST_LINE=$(head -n 1 out.csv)
56+
57+
if [[ "$FIRST_LINE" == "$HEADER"* ]]; then
58+
echo "Header is valid"
59+
else
60+
echo "Header is invalid"
61+
exit 1
62+
fi
63+
5264
- name: Show out.csv
5365
run: cat out.csv

0 commit comments

Comments
 (0)