-
Notifications
You must be signed in to change notification settings - Fork 247
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_: separate commit message check #5773
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Jenkins BuildsClick to see older builds (174)
|
igor-sirotin
force-pushed
the
fix/separate-commit-message-ceck
branch
7 times, most recently
from
August 27, 2024 16:33
ecd34e5
to
691ee47
Compare
igor-sirotin
force-pushed
the
fix/separate-commit-message-ceck
branch
from
August 27, 2024 16:42
691ee47
to
1d1d162
Compare
igor-sirotin
changed the title
fix_: separate commit message ceck
fix_: separate commit message check
Aug 27, 2024
igor-sirotin
commented
Aug 27, 2024
# Run the loop in the current shell using process substitution | ||
while IFS= read -r message || [ -n "$message" ]; do | ||
# Check if commit message follows conventional commits format | ||
if [[ $message =~ ^(build|chore|ci|docs|feat|fix|perf|refactor|revert|style|test)(\(.*\))?(\_|!):.*$ ]]; then | ||
# Check for breaking changes | ||
if [[ ${BASH_REMATCH[3]} == *'!'* ]]; then | ||
is_breaking_change=true | ||
break |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This break
is wrong. We should check all commits.
jakubgs
approved these changes
Aug 27, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like a good way to raise visibility.
osmaczko
approved these changes
Aug 27, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
We want a separate check for commit messages. When an issue happen with commit messages, we still want to know tests run results. Because sometimes we want for force-merge. And because it makes sense in general, it's easier to see the issue fro the developer.
Also, I fixed a bug. A commit with breaking change would mitigate a commit with malformed message.
Inspired by go-waku repository
edit
Comment when commit check is not passing
The comment is automatically deleted when the issues are resolved.
Comment when commit check is passing and breaking changes are detected