Skip to content

Commit

Permalink
Try output
Browse files Browse the repository at this point in the history
  • Loading branch information
katjuell committed Oct 1, 2024
1 parent 17fb754 commit a9fdc33
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions .github/workflows/presubmit-metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,17 @@ jobs:
echo 'Verifying allowed keywords ...'
# Don't fail because of grep
set +o pipefail
{find ./images -name '*metadata.yaml' | while read -r file; do
find ./images -name '*metadata.yaml' | while read -r file; do
if yq eval '.keywords[]' "$file" | grep -voE '(application|base|fips|ai|ai-gpu|stigs|featured)'; then
echo "$file" has keywords that are not on allow list. Please update.
cat "$file" has keywords that are not on allow list. Please update. >> output_log.txt
fi
done} >> $GITHUB_OUTPUT
done
- name: Output results
shell: bash
id: output-results
run: |
set -e
if [ -s output_log.txt ]; then
cat output_log.txt >> $GITHUB_OUTPUT
exit 1
fi

0 comments on commit a9fdc33

Please sign in to comment.