Integrate the commit message checker github action
The Portal project recently integrated commitlint to check for incorrect commit messages.
Can we integrate this for other projects?
yesss! I mean, how does this work? Does this avoid a squash and merge with the wrong commit message? What is the workflow here? @SanketDG
@isabelcosta Well, it just parses the commit message for a set of rules and then throws an error for the failed github action! (like tests have failed)
Sample: https://github.com/anitab-org/portal/pull/566
can i work on this??
Sure @19-pragya, should I assign you?
Yes please
Let me know if you need any help.
actually, i am very new to this.. can you please explain waht exactly i have to to?? @SanketDG
@19-pragya
Most projects at Anita-B have a Commit Message Style Guide, which is adhered by all developers when updating or creating commits for a PR. This is Portal's.
This was mostly checked by each and every PR reviewer manually, which is not the most effecient way to do it. So, why not let computers do what they are good what?
https://github.com/anitab-org/portal/pull/607 introduced commitlint to automatically do this, so that reviewers don't have to check for each commit. Here's an example (if you scroll down you will see the commit message check failing) Here's the list of steps that one needs to do here:
- Find a project under Anita-B that has a commit message style guide
- Configure
commitlintto use the set of rules as specified by the style guide - Open a PR!
This is not a beginner or first timer issue, but feel free to ask for help on here or Zulip if you choose to do this!