Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake format and lint in pre-commit #2683

Merged
merged 5 commits into from
Feb 13, 2024
Merged

Conversation

tylerjw
Copy link
Member

@tylerjw tylerjw commented Feb 13, 2024

  • cmake-format
  • cmake_lint
  • Drop ament_lint_cmake

Description

I think it is a much better developer experience having cmake consistently formatted and linted in pre-commit than in ament.

Copy link

codecov bot commented Feb 13, 2024

Codecov Report

Attention: 29 lines in your changes are missing coverage. Please review.

Comparison is base (d962501) 50.74% compared to head (b830011) 41.08%.
Report is 6 commits behind head on main.

Files Patch % Lines
...default_capabilities/get_group_urdf_capability.cpp 0.00% 23 Missing ⚠️
...nning_scene_monitor/src/planning_scene_monitor.cpp 40.00% 3 Missing ⚠️
.../rdf_loader/include/moveit/rdf_loader/rdf_loader.h 0.00% 2 Missing ⚠️
...py/src/moveit/moveit_ros/moveit_cpp/moveit_cpp.cpp 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2683      +/-   ##
==========================================
- Coverage   50.74%   41.08%   -9.66%     
==========================================
  Files         392      690     +298     
  Lines       32553    56237   +23684     
  Branches        0     7288    +7288     
==========================================
+ Hits        16517    23098    +6581     
- Misses      16036    32976   +16940     
- Partials        0      163     +163     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@sjahr sjahr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thank you! For some reason, this change leads to a huge amount of failures like this:

- moveit_core.cpplint whitespace/line_length [2] (/home/runner/work/moveit2/moveit2/.work/target_ws/src/moveit2/moveit_core/collision_detection_bullet/src/bullet_integration/bullet_utils.cpp:226)
  <<< failure message
    Lines should be <= 100 characters long

Do you know why this is happening? Once it is fixed, we can merge this

@tylerjw
Copy link
Member Author

tylerjw commented Feb 13, 2024

Awesome, thank you! For some reason, this change leads to a huge amount of failures like this:

- moveit_core.cpplint whitespace/line_length [2] (/home/runner/work/moveit2/moveit2/.work/target_ws/src/moveit2/moveit_core/collision_detection_bullet/src/bullet_integration/bullet_utils.cpp:226)
  <<< failure message
    Lines should be <= 100 characters long

Do you know why this is happening? Once it is fixed, we can merge this

Yea, I do and I'll fix it.

@tylerjw
Copy link
Member Author

tylerjw commented Feb 13, 2024

Here is the list of linters that come from ament_lint. Now that we are dropping cmake-lint and using it in pre-commit none of these make much sense for us so I'm going to drop all of them.

https://github.com/ament/ament_lint/blob/rolling/ament_lint_common/doc/index.rst

@tylerjw tylerjw merged commit b7bb669 into moveit:main Feb 13, 2024
9 of 11 checks passed
@tylerjw tylerjw deleted the cmake-format-and-lint branch February 13, 2024 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants