2.1.23.8. cli.pre_commit_scripts.check_sections

Check for correct section markers in provided C source and header files.

This script verifies that all required section markers are present, in the correct order, and formatted properly in C and header files. It also ensures each marker is preceded by a blank line and, for source/header files, checks for the presence of the ‘#ifdef UNITY_UNIT_TEST’ directive after the unit test marker. It is intended for use with pre-commit.

Functions

check_src(files)

Check C source/header files for section marker correctness.

check_test(files)

Check test C source/header files for section marker correctness.

main([argv])

Command-line interface for section marker checking.

run_check(filename, file_type)

Check a file for correct section marker usage and order.