mirror of
https://github.com/lvgl/lvgl.git
synced 2026-05-24 00:07:03 +08:00
ci(doxygen): add automated Doxygen comment completeness check for public API
Add scripts/check_doxygen.py to validate that public lv_* function declarations in src/**/*.h have proper Doxygen comments with @param and @return tags. Current state: 2505 functions, 77% fully compliant, 670 legacy issues. The CI check is incremental (diff-only) so legacy debt is not flagged. Features: - --diff mode for CI (only checks PR-changed lines) - --all mode for full scan - --self-test with 37 built-in test cases - --timeout per-file protection (default 5s) - Skips libs/, *_gen.h, lv_conf*, lv_api_map* - Handles multi-line decls, function pointers, [in]/[out] qualifiers - Scans 577 headers in ~0.4s
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
name: Verify Doxygen comments on public API
|
||||
on:
|
||||
pull_request:
|
||||
|
||||
# https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#concurrency
|
||||
concurrency:
|
||||
group: ${{ github.ref }}-${{ github.workflow }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
check-doxygen:
|
||||
if: ${{ github.repository != github.event.pull_request.head.repo.full_name }}
|
||||
runs-on: ubuntu-24.04
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
persist-credentials: false
|
||||
fetch-depth: 0
|
||||
- name: Setup Python
|
||||
uses: actions/setup-python@v6
|
||||
with:
|
||||
python-version: '3.12'
|
||||
- name: Self-test Doxygen checker
|
||||
run: python3 scripts/check_doxygen.py --self-test
|
||||
- name: Check Doxygen comments on changed headers
|
||||
run: |
|
||||
git fetch --no-tags --prune origin \
|
||||
${{ github.event.pull_request.base.sha }} \
|
||||
${{ github.event.pull_request.head.sha }}
|
||||
MB=$(git merge-base \
|
||||
${{ github.event.pull_request.base.sha }} \
|
||||
${{ github.event.pull_request.head.sha }})
|
||||
echo "Merge-base: $MB"
|
||||
python3 scripts/check_doxygen.py \
|
||||
--diff "${MB}...${{ github.event.pull_request.head.sha }}" \
|
||||
--timeout 5
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user