Skip to content

feat: support revert commits#29

Merged
michen00 merged 10 commits intomainfrom
feat/support-revert-commits
Jan 30, 2026
Merged

feat: support revert commits#29
michen00 merged 10 commits intomainfrom
feat/support-revert-commits

Conversation

@michen00
Copy link
Owner

@michen00 michen00 commented Jan 27, 2026

This pull request extends the project's conventional commit message validation to include support for revert and reapply operations. It ensures that these specific commit types are correctly identified, categorized, and formatted according to established conventions, thereby maintaining consistency in the commit history. This change also includes minor stylistic updates to pre-commit configurations and expanded test coverage.

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @michen00, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request extends the project's conventional commit message validation to include support for revert and reapply operations. It ensures that these specific commit types are correctly identified, categorized, and formatted according to established conventions, thereby maintaining consistency in the commit history. This change also includes minor stylistic updates to pre-commit configurations and expanded test coverage.

Highlights

  • New Commit Message Type Support: The conventional-merge-commit script now recognizes and processes revert and reapply commit messages, expanding the types of commits handled by the system.
  • Commit Message Transformation Logic: Specific logic has been implemented to transform revert and reapply messages into the revert: <original message> format, ensuring consistent conventional commit prefixes.
  • Expanded Test Coverage: Comprehensive test cases have been added in both .csv and .sh files to validate the correct parsing and transformation of these new revert and reapply commit message types under various conditions.
  • Pre-commit Hook Style Consistency: The .pre-commit-config.yaml file was updated to standardize the use of single quotes for arguments in several pre-commit hooks, improving stylistic consistency.
  • Git Blame Ignore Update: A new commit hash was added to .git-blame-ignore-revs, likely to ignore a style-related commit when performing git blame.
Ignored Files
  • Ignored by pattern: .github/workflows/** (1)
    • .github/workflows/CI.yml
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@codecov-commenter
Copy link

codecov-commenter commented Jan 27, 2026

Codecov Report

❌ Patch coverage is 85.04673% with 16 lines in your changes missing coverage. Please review.
✅ Project coverage is 73.21%. Comparing base (54f683e) to head (eb7c13c).

Files with missing lines Patch % Lines
scripts/conventional-merge-commit 0.00% 14 Missing ⚠️
tests/test-integration.sh 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #29      +/-   ##
==========================================
+ Coverage   69.17%   73.21%   +4.04%     
==========================================
  Files          12       12              
  Lines         639      728      +89     
==========================================
+ Hits          442      533      +91     
+ Misses        197      195       -2     
Flag Coverage Δ
integration 2.79% <0.00%> (-0.36%) ⬇️
unit 71.52% <85.04%> (+4.28%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request adds support for handling revert and reapply commit messages in the conventional-merge-commit script, along with extensive tests. The changes are well-implemented and tested. I've suggested a small refactoring in the shell script to reduce code duplication and improve maintainability. Otherwise, the changes look good.

Repository owner deleted a comment from github-actions bot Jan 27, 2026
@michen00 michen00 force-pushed the feat/support-revert-commits branch from d4efd26 to 3f03aeb Compare January 27, 2026 17:28
@michen00 michen00 marked this pull request as ready for review January 27, 2026 18:09
@michen00
Copy link
Owner Author

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request effectively extends the conventional commit message validation to support revert and reapply commit types. The changes are logical, and the addition of comprehensive tests in both unit and integration testing files is commendable. I have one suggestion to refactor a part of the shell script to improve maintainability by reducing code duplication.

Copy link
Contributor

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a9bc9ebd9a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@michen00
Copy link
Owner Author

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request effectively extends the conventional commit message validation to support revert and reapply operations. The changes are well-structured, and the addition of comprehensive test cases significantly improves the robustness of the script. I have one suggestion to refactor a small part of the shell script to improve its conciseness and maintainability. Overall, this is a solid contribution.

@michen00
Copy link
Owner Author

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request effectively extends conventional commit message validation to support revert and reapply operations, with thorough test coverage. The changes are well-structured. I have one suggestion for the main script to simplify the implementation, making it more consistent with the existing code and improving maintainability.

@michen00
Copy link
Owner Author

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request effectively extends the conventional commit message validation to support revert and reapply operations, which is a great enhancement for maintaining a consistent commit history. The changes are well-implemented, and the accompanying tests are thorough, covering numerous edge cases. I have one minor suggestion to improve the readability of the pattern-matching logic in the main script. Overall, this is a high-quality contribution.

@michen00
Copy link
Owner Author

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request effectively adds support for revert and reapply commit messages to the conventional commit hook. The changes are logical, and the addition of extensive test cases, including positive, negative, and edge cases, is excellent. I have one suggestion to improve the readability of the pattern matching logic in the main script, which will enhance future maintainability.

@michen00 michen00 merged commit 39e52ee into main Jan 30, 2026
13 checks passed
@michen00 michen00 deleted the feat/support-revert-commits branch January 30, 2026 17:15
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.

2 participants