File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -16,12 +16,20 @@ jobs:
1616 if : ' !cancelled()'
1717 run : |
1818 clang-format -i */*.[ch]
19- if git diff | grep ""; then
20- (echo "Formatting errors detected by clang-format." \
21- "Please run \`make format\`.";
19+ git diff > formatting-fixes.diff
20+ if ! grep "" formatting-fixes.diff; then
21+ rm -f formatting-fixes.diff
22+ else
23+ (echo "Formatting errors detected by clang-format. Please run" \
24+ "\`make format\` or apply formatting-fixes.diff below.";
2225 echo) >> $GITHUB_STEP_SUMMARY
2326 false
2427 fi
28+ - uses : actions/upload-artifact@v4
29+ with :
30+ if-no-files-found : ignore
31+ name : formatting-fixes.diff
32+ path : formatting-fixes.diff
2533 - name : Check C89 compliance
2634 if : ' !cancelled()'
2735 env :
You can’t perform that action at this time.
0 commit comments