[CI] (.github/workflows, CONTRIBUTING.md, scripts, scripts/data): add the layering and size ratchets

This commit is contained in:
2026-10-16 04:01:29 -04:00
parent 26a30ecd02
commit f90537c3cb
4 changed files with 444 additions and 5 deletions
+10 -4
View File
@@ -1,8 +1,9 @@
name: Text hygiene
# CONTRIBUTING.md's checks: the pushed commits' messages, the source-text rules and ratchets, and
# clang-format on each commit's changed lines. This is its own workflow without a concurrency
# group, so a later push never cancels it and every push's commits are checked.
# CONTRIBUTING.md's checks: the pushed commits' messages, the source-text rules and ratchets,
# clang-format on each commit's changed lines, and the layering and size ratchets. This is its own
# workflow without a concurrency group, so a later push never cancels it and every push's commits
# are checked.
on:
push:
branches: ['**']
@@ -29,6 +30,11 @@ jobs:
"${RUNNER_TEMP}/clang-format/bin/pip" install --quiet 'clang-format==23.1.3'
echo "CLANG_FORMAT=${RUNNER_TEMP}/clang-format/bin/clang-format" >> "${GITHUB_ENV}"
- name: Lint self-test
run: python3 scripts/check_text_hygiene.py self-test
run: |
python3 scripts/check_text_hygiene.py self-test
python3 scripts/check_structure.py self-test
- name: Check commits, source text and formatting
run: python3 scripts/check_text_hygiene.py ci
- name: Check layering and file and function size
if: ${{ !cancelled() }}
run: python3 scripts/check_structure.py ci