Skip to content

Commit

Permalink
addons/namingng.py: Reinstate dict-with-regexps, cosmetic overhaul. (#…
Browse files Browse the repository at this point in the history
…5824)

`namingng.py` somewhat supported specifying a dict instead of a list for
regular expressions, until the feature was broken by a patch of mine
recently. This PR contains a patch rewriting the feature and expanding
relevant unit tests.

To improve maintainability, a second patch is added that refactors the
code for better readability and structure.
  • Loading branch information
mvds00 committed Jan 4, 2024
1 parent 481d457 commit 21a9de7
Show file tree
Hide file tree
Showing 3 changed files with 217 additions and 209 deletions.
2 changes: 1 addition & 1 deletion addons/ROS_naming.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"RE_FILE": {".*[A-Z]": [true, "under_scored"]},
"RE_FILE": [".*[A-Z]"],
"RE_NAMESPACE": {".*[A-Z]": [true, "under_scored"],
".*\\_$": [true, "under_scored"]},
"RE_FUNCTIONNAME": {".*\\_": [true, "camelCase"],
Expand Down
Loading

0 comments on commit 21a9de7

Please sign in to comment.