Skip to content

Commit

Permalink
ci: ekf change check only commit if files updated
Browse files Browse the repository at this point in the history
  • Loading branch information
mrpollo committed Nov 28, 2024
1 parent 67754d6 commit dbe8ca5
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/ekf_update_change_indicator.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,21 @@ jobs:
make tests TESTFILTER=EKF
- name: Check if there exists diff and save result in variable
run: echo "CHANGE_INDICATED=$(git diff --exit-code --output=/dev/null || echo $?)" >> $GITHUB_ENV
id: diff-check
run: echo "CHANGE_INDICATED=$(git diff --exit-code --output=/dev/null || echo $?)" >> $GITHUB_OUTPUT
working-directory: src/modules/ekf2/test/change_indication

- name: auto-commit any changes to change indication
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: '[AUTO COMMIT] update change indication'
file_pattern: 'src/modules/ekf2/test/change_indication/*.csv'
commit_user_name: ${GIT_COMMITTER_NAME}
commit_user_email: ${GIT_COMMITTER_EMAIL}
commit_message: |
'[AUTO COMMIT] update change indication'
See .github/workflopws/ekf_update_change_indicator.yml for more details
- name: if there is a functional change, fail check
if: ${{ env.CHANGE_INDICATED }}
if: ${{ steps.diff-check.outputs.CHANGE_INDICATED }}
run: exit 1

0 comments on commit dbe8ca5

Please sign in to comment.