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

Add a validate command to CLI to validate commit messages #58

Merged
merged 9 commits into from
Oct 7, 2022

Conversation

hussainweb
Copy link
Contributor

@hussainweb hussainweb commented Jul 21, 2022

Description

As discussed in #57 (comment), this PR adds a command to validate a commit message

Motivation and context

More details in #57 and #25.

How has this been tested?

So far, I have added a few tests and mainly tested this manually. This PR is WIP and I will add more tests.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

PR checklist

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING.md document.
  • I have added tests to cover my changes.

@hussainweb hussainweb requested a review from ramsey as a code owner July 21, 2022 19:44
@hussainweb
Copy link
Contributor Author

I am not sure what to do with the phpstan error in the static analysis stage. FWIW, this breaks on the main branch as well. If I find a fix, I'll submit another PR for that.

@Whax
Copy link

Whax commented Aug 16, 2022

Hello,

I'm really interested with this PR, @hussainweb any news ? :)

Thanks

@hussainweb
Copy link
Contributor Author

@ramsey, I have found why there is an error with PHPStan and created #64. Can you please take a look?

@hussainweb
Copy link
Contributor Author

hussainweb commented Oct 3, 2022

I'm happy to see most relevant checks are passing now. More tests and docs next. I can't do that today though. Maybe tomorrow or later this week.

@codecov
Copy link

codecov bot commented Oct 3, 2022

Codecov Report

Merging #58 (b937c51) into main (a9a668b) will increase coverage by 0.05%.
The diff coverage is 100.00%.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##               main      #58      +/-   ##
============================================
+ Coverage     98.71%   98.76%   +0.05%     
- Complexity      286      296      +10     
============================================
  Files            37       39       +2     
  Lines           779      813      +34     
============================================
+ Hits            769      803      +34     
  Misses           10       10              
Impacted Files Coverage Δ
...ntionalCommits/Console/Command/ValidateCommand.php 100.00% <100.00%> (ø)
...tionalCommits/Console/Question/MessageQuestion.php 100.00% <100.00%> (ø)

@hussainweb
Copy link
Contributor Author

Cool. Codecov is happy. I'll work on the docs tomorrow.

@hussainweb
Copy link
Contributor Author

@ramsey, I completed all the tasks and requesting a review now. Thanks!

Copy link
Owner

@ramsey ramsey left a comment

Choose a reason for hiding this comment

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

Looks great. Thanks! 🎉

@ramsey ramsey merged commit 32edb54 into ramsey:main Oct 7, 2022
@hussainweb hussainweb deleted the validate-command branch October 11, 2022 15:41
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.

3 participants