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
fix(changelog): group regexps #3527
Conversation
5a9a565
to
708f44f
Compare
Codecov Report
@@ Coverage Diff @@
## main #3527 +/- ##
==========================================
+ Coverage 84.26% 84.27% +0.01%
==========================================
Files 114 114
Lines 9329 9338 +9
==========================================
+ Hits 7861 7870 +9
Misses 1191 1191
Partials 277 277
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
e1f063d
to
079b5bd
Compare
Had to roll back some changes which worked with the tests but didn't work in practice on github which has different output. I went with a conservative non greedy |
079b5bd
to
01bbd38
Compare
Fix the regular expressions used in changelog group processing to valid golang (RE2) regexps. These previously used PCRE character class \w which is not supported in RE2 which is what golang regexp uses. Document that format matches not just title as some may thing but the format "<abbrev-commit> <title-commit>". This also include "!" as defined by conventional commits.
Note changelog group regexp parameters are in RE2 syntax.
Use [[:xdigit:]] to match the abbrev-commit, which is clearer as to the intent and correct as the previous version had a typo anyway.
GitHub has different output than the tests, including a colon after the commit reference, so make the pattern resilient to that and other nuisances by making it a full wild card but non greedy. Also: * Remove processed entries instead of striking them out, allowing early exit when we're done. * Add group match debugging to users can see what's going on with --debug.
Fix invalid invalid index access in changelog processing when removing processed items.
dd73294
to
ffe9559
Compare
thank you! |
Fix the regular expressions used in changelog group processing to valid golang (RE2) regexps. These previously used PCRE character class
\w
which is not supported in RE2 which is what golang regexp uses.Also document that format matches not just title as some may thing but the format
<abbrev-commit> <title-commit>
.