2023-01-01 06:46:17 +06:00
|
|
|
name: PR Regenerate Files
|
|
|
|
|
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
paths:
|
|
|
|
- 'data/constants/**'
|
|
|
|
- 'lib/python/**'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
regen:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
2023-03-17 07:32:09 +06:00
|
|
|
container: ghcr.io/qmk/qmk_cli
|
2023-01-01 06:46:17 +06:00
|
|
|
|
|
|
|
steps:
|
2023-03-01 02:27:11 +06:00
|
|
|
- name: Disable safe.directory check
|
|
|
|
run : git config --global --add safe.directory '*'
|
|
|
|
|
2023-09-05 23:50:04 +06:00
|
|
|
- uses: actions/checkout@v4
|
2023-01-01 06:46:17 +06:00
|
|
|
|
|
|
|
- name: Run qmk generators
|
|
|
|
run: |
|
|
|
|
util/regen.sh
|
|
|
|
git diff
|
|
|
|
|
|
|
|
- name: Fail when regeneration required
|
|
|
|
run: |
|
|
|
|
git diff
|
|
|
|
for file in $(git diff --name-only); do
|
|
|
|
echo "File '${file}' Requires Regeneration"
|
|
|
|
echo "::error file=${file}::Requires Regeneration"
|
|
|
|
done
|
|
|
|
test -z "$(git diff --name-only)"
|