1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-28 07:03:00 +08:00

ci apply my updates to the verify-formatting action

This commit is contained in:
embeddedt 2021-12-12 21:44:14 -05:00 committed by GitHub
parent d1ccbf607f
commit 02f02fa78f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -21,4 +21,19 @@ jobs:
run: python code-format.py
working-directory: scripts
- name: Check that repository is clean
run: git diff --exit-code --color=always || (echo "Please apply the preceding diff to your code or run scripts/code-format.sh"; false)
shell: bash
run: |
set -o pipefail
if ! (git diff --exit-code --color=always | tee /tmp/lvgl_diff.patch); then
echo "Please apply the preceding diff to your code or run scripts/code-format.sh"
exit 1
fi
- name: Comment PR
uses: thollander/actions-comment-pull-request@v1
if: github.event_name == 'pull_request' && failure()
with:
message: |
Your PR needs its formatting corrected before it can be merged upstream.
Please comment `@lvgl-bot format` if you would like our bot to commit this change for you.
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}