CMakePP / CMinx

Generates API documentation for CMake functions and macros
https://cmakepp.github.io/CMinx/
Apache License 2.0
14 stars 5 forks source link

Add regex option and implement regex stripping in function aggregator #151

Closed AutonomicPerfectionist closed 1 year ago

AutonomicPerfectionist commented 1 year ago

Is this pull request associated with an issue(s)? Fixes #149 Description This PR adds another option to the config, this one allows users to strip characters from parameter names for function, macro, and method definitions. Most of CMakeTest's parameters have prefixes to prevent name collisions, and this PR would make those parameters easier to read.

I have also updated documentation and type hints in this PR, as I found a large number had not been updated. This PR also fixes a previously-undiscovered bug where option() generated RST with too many indents in the .. note:: directive.

TODOs

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 99.37% and project coverage change: +0.07 :tada:

Comparison is base (ea6d33e) 97.10% compared to head (947ea13) 97.17%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #151 +/- ## ========================================== + Coverage 97.10% 97.17% +0.07% ========================================== Files 8 8 Lines 966 992 +26 ========================================== + Hits 938 964 +26 Misses 28 28 ``` | Flag | Coverage Δ | | |---|---|---| | unittests | `97.17% <99.37%> (+0.07%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP#carryforward-flags-in-the-pull-request-comment) to find out more. | [Impacted Files](https://app.codecov.io/gh/CMakePP/CMinx/pull/151?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP) | Coverage Δ | | |---|---|---| | [src/cminx/rstwriter.py](https://app.codecov.io/gh/CMakePP/CMinx/pull/151?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP#diff-c3JjL2NtaW54L3JzdHdyaXRlci5weQ==) | `98.26% <98.68%> (+0.01%)` | :arrow_up: | | [src/cminx/aggregator.py](https://app.codecov.io/gh/CMakePP/CMinx/pull/151?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP#diff-c3JjL2NtaW54L2FnZ3JlZ2F0b3IucHk=) | `95.57% <100.00%> (+0.07%)` | :arrow_up: | | [src/cminx/config.py](https://app.codecov.io/gh/CMakePP/CMinx/pull/151?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP#diff-c3JjL2NtaW54L2NvbmZpZy5weQ==) | `100.00% <100.00%> (ø)` | | | [src/cminx/documentation\_types.py](https://app.codecov.io/gh/CMakePP/CMinx/pull/151?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP#diff-c3JjL2NtaW54L2RvY3VtZW50YXRpb25fdHlwZXMucHk=) | `98.40% <100.00%> (+0.02%)` | :arrow_up: | | [src/cminx/documenter.py](https://app.codecov.io/gh/CMakePP/CMinx/pull/151?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP#diff-c3JjL2NtaW54L2RvY3VtZW50ZXIucHk=) | `100.00% <100.00%> (ø)` | | | [src/cminx/exceptions.py](https://app.codecov.io/gh/CMakePP/CMinx/pull/151?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=CMakePP#diff-c3JjL2NtaW54L2V4Y2VwdGlvbnMucHk=) | `100.00% <100.00%> (ø)` | |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.