Skip to content

Conversation

@2bndy5
Copy link
Collaborator

@2bndy5 2bndy5 commented Oct 21, 2021

This fixes a couple scenarios:

  1. If clang-format failed to run then the action would crash when trying to parse XML data that doesn't exist.
    • clang-format can fail to run when an unsupported option is set in the .clang-format file. This problem is usually avoided by setting the correct version number for which the .clang-format file was designed.
  2. Parsing the ignore paths used str.lstrip("./") which would lead to stripping the left-most . OR /. I have replaced lstrip("./") with str.replace("./", "", 1), so only the exact left-most sequence of ./ is stripped.
    • Also, I fixed stripping the left-most ./ in a path that was prefixed with a !. Previously the relative path syntax was only striped from paths that didn't have the ! prefix.

@2bndy5
Copy link
Collaborator Author

2bndy5 commented Oct 21, 2021

It feels good to be done adding features and just fixing bugs. With every bug I find and fix, I feel that we are that much closer to a solid solution.

Copy link
Collaborator

@shenxianpeng shenxianpeng left a comment

Choose a reason for hiding this comment

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

Yes, agree, only introducing this action to the real project could help to improve it.
Approved and ready to merge.

@shenxianpeng shenxianpeng merged commit 3ad10e1 into cpp-linter:master Oct 21, 2021
@shenxianpeng shenxianpeng added the bug Something isn't working label Oct 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants