mirror of
https://github.com/MobileGL-Dev/MobileGL
synced 2026-11-07 18:13:23 +09:00
[CI] (.github/workflows, scripts, scripts/data): check commit messages, comment text and formatting
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
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.
|
||||
on:
|
||||
push:
|
||||
branches: ['**']
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
text-hygiene:
|
||||
name: Commit messages and source text
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 15
|
||||
env:
|
||||
TEXT_HYGIENE_BASE_BRANCH: feat/disaggregated
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Install clang-format
|
||||
run: |
|
||||
python3 -m venv "${RUNNER_TEMP}/clang-format"
|
||||
"${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
|
||||
- name: Check commits, source text and formatting
|
||||
run: python3 scripts/check_text_hygiene.py ci
|
||||
Reference in New Issue
Block a user