Test gh actions #6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check crd and readme updates | |
on: | |
pull_request: | |
paths: | |
- "apis/**" | |
jobs: | |
file-updates: | |
name: Test file updates | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: run make commands | |
run: | | |
make generate && make manifests && make api-docs | |
- name: check unstaged files | |
id: check_unstaged_files | |
run: | | |
if [[ -z $(git status -s) ]] | |
then | |
echo "is_files_unstaged=false" >> $GITHUB_OUTPUT | |
else | |
echo "is_files_unstaged=true" >> $GITHUB_OUTPUT | |
exit | |
fi | |
- name: create pr comments and fail checks | |
if: ${{ steps.check_unstaged_files.is_files_unstaged }} == true | |
run: | | |
git log |